Chris Rock had some useful advice for John Mulaney after he announced his divorce.

Rock chatted to Jimmy Fallon on Tuesday’s “Tonight Show” after Mulaney and wife Annamarie Tendler confirmed they’d split after six years of marriage earlier this month.

“This is how much money I lost in my divorce,” Rock, who split from his wife Malaak Compton-Rock in 2014 after 18 years of marriage, joked, adding: “I recommended my ex-wife’s divorce lawyer.”

“I was like, ‘You should get this guy,'” he quipped. “He’ll get you your money. This guy’s good. I walked out with nothing.'”

Rock insisted, laughing: “You think I’m joking. I really did.”

RELATED: Chris Rock Talks Returning To Standup, Dating & The Pitfalls Of Wearing A Mask

Rock recently served as an opening act for Mulaney during a string of sold-out shows in New York.

Mulaney’s divorce news comes after he completed a 60-day stint in rehab following a long battle with addiction.

Rock’s “Tonight Show” appearance also saw him talk about getting his COVID-19 vaccine, as well as revealing how Eddie Murphy gave him his big break in “Beverly Hills Cop 2”.

The comedian then spoke about his new film “Spiral: From the Book of Saw” and working on the project with Samuel L. Jackson. He was joined by 21 Savage to play a game of “True Confessions”.