TORONTO — Embattled Toronto Mayor Rob Ford laughed off Jimmy Kimmel’s suggestion that he get help for his drinking problem and was reported to be upset about his appearance on the late night TV talk show.

Ford’s appearance Monday night on “Jimmy Kimmel Live” in Los Angeles was the culmination of months of wooing by the talk show host to get Ford to appear as a guest.

Ford tossed T-shirts to the audience to loud applause as he came on stage after Kimmel introduced him by saying “our first guest tonight has tripped, bumped, danced, argued and smoked his way into our national consciousness.”

Kimmel told Ford that if he’s an alcoholic, and drinking enough that he would try crack cocaine in his 40s, “and you don’t remember it, maybe that’s something that you might want to think about, like talking to somebody.”

Ford shot back his head and laughed before saying he “wasn’t elected to be perfect.”

“I was elected to clean up the mess that I inherited, and that’s exactly what I did,” Ford said, defending his record as mayor.

Ford made international headlines last year when he acknowledged having smoked crack cocaine while in a drunken stupor. He continues to draw attention for his erratic behavior, but has resisted pressure to step down and is seeking re-election in October.

The audience applauded after Kimmel told Ford that accepting help “is nothing to be ashamed of” and would set a “good example for other people who might be in a similar situation.” When asked again about getting help, Ford said: “Talk is cheap, action speaks louder than words. We’ll let the people decide on October 27. I’m just a normal, average, hard-working politician that’s real.”

“You are not the average politician,” Kimmel quipped. “You are the most wonderful mayor I’ve ever witnessed.”

Ford and Kimmel earlier left their seats during the segment to watch a series of videos depicting the mayor of Canada’s largest city in a variety of embarrassing scenes, including a cell phone video of Ford ranting about wanting to kill someone. Ford said he didn’t know who he was talking about in the video.

“You have no idea?” an incredulous Kimmel asked. “You have that many enemies that you don’t know which one this was?”

Kimmel also played several other videos, including one from a city council meeting in which he mimes a drunk driver and another that shows him dumping and throwing — not handing — candy canes to children during a Santa Claus parade. The red-faced mayor stood next to a video screen and was asked to comment about each of them.

Kimmel earlier dabbed sweat pouring off of Ford’s forehead with tissues and asked Ford why he had agreed to come on the show.

“Why are you here? What good could come of this? Have you ever seen the show?” said Kimmel, who had repeatedly skewered Ford on his show.

Doug Ford, the mayor’s brother who traveled with the mayor to Los Angeles, later told The Toronto Sun that the mayor “was a little upset” after appearing on the show. The Sun reporter wrote that he heard the mayor say in the background of the phone call that he was “set up.”

Doug Ford and a spokesman for the mayor didn’t immediately respond to messages seeking comment.

Before the show, Ford had said that his appearance on Kimmel’s show was intended to promote Toronto’s film industry, describing his city as “Hollywood North.”