TORONTO (AP) – It took Eddie Murphy more than a decade to get a movie made about Rudy Ray Moore. Judging by the response to the film at the Toronto International Film Festival, the wait was worth it.

“Dolemite Is My Name” drew some of the best reviews of Murphy’s career, following the film’s premiere over the weekend in Toronto. It had been a while. Murphy’s last two leading performances – 2016’s “Mr. Church” and 2012’s “A Thousand Words” – were little seen and little loved.

But “Dolemite Is My Name” was a passion project for the 58-year-old comedian. He long ago met with Moore, who died in 2008 at the age of 81, to discuss making a movie about the comedian. Moore’s famous character – the straight-talking, kung fu-fighting pimp Dolemite – was his stand-up persona and star of the 1975 classic “Dolemite.”

“I never let go of the idea. It was always something I thought could be a great movie. I had been sitting on the couch. I took some time to do nothing,” Murphy said in an interview. “It goes back to when Rudy was alive. I literally went to see him at a club. It just didn’t come together. And there was no Netflix back then.”

“Dolemite Is My Name,” directed by Craig Brewer “Hustle & Flow”), will be released by Netflix in theaters Oct. 4 and begin streaming on Oct. 25. It’s penned by Scott Alexander and Larry Karaszewski, who memorably wrote another tale about an inexpert filmmaker: “Ed Wood.”

“Dolemite Is My Name” chronicles the ramshackle, threadbare making of “Dolemite” with Wesley Snipes playing director D’Urville Martin. It’s a paean to low-budget moviemaking and a celebration of creating something out of nothing, outside a movie system that made scant room for African-American stories.

For Brewer, a Memphis, TN, native, it’s a testament to the independent filmmaking of his youth.

“I came up in my career as a guerrilla filmmaker. You show up and you shoot. You don’t have permits. You don’t have professionals help you. You just have a bunch of other people like you who have a blind passion,” Brewer said. “Sometimes those passion projects turn into something wonderful even though they’re terrible.”

For “My Name Is Dolemite,” the reception in Toronto was electric – especially for a performance that for many recalled Murphy’s performances of the ’80s. During the standing ovation that followed the film’s premiere, cast member Keegan-Michael Key suggested the lengthy applause shouldn’t stop for Murphy.

“We should just stand all night and clap for him,” Key said.

The film has helped kick off a comeback for Murphy. After years of working seldom if at all, Murphy is currently shooting a sequel to “Coming to America,” also with Brewer directing and Snipes co-starring. Later this year, the former “Saturday Night Live” cast member will host the show for the first time since 1984. And after years away from the stage, he’s plotting a return to stand-up, with a tour planned for next summer.

But before all that, Murphy was again performing stand-up, only as Rudy Ray Moore and outfitted in the costumes designed by Oscar-winner Ruth Carter for “My Name Is Dolemite.” The filmmakers recognized what a privileged sight they were watching.

“Eddie comes in as Rudy and he starts telling jokes. And like Eddie does, he goes completely off book. If something comes, he just rolls into it,” Brewer said.

“Then he left and I turned to the audience and said, ‘Y’all, do you realize what just happened? I don’t think he’s done that in like years! Decades!’”