You don’t expect to see a movie named “Dicks: The Musical” on the marquee, and neither did its makers.

It’s the nature of creating a delirious, Dadaist riff on “The Parent Trap” — only with two obviously dissimilar gay men as long-lost identical twins and Bowen Yang playing God — that you can never be sure it’s really happening. Josh Sharp and Aaron Jackson, who created and star in “Dicks: The Musical,” certainly struggled to believe it.

“Every step of the way we thought it would fall through,” Jackson says. “It really wasn’t until visiting the sets and walking through those that it was like: ‘Oh my God, they’re going to make it.’ ”

The movies are awash in more of the same, but “Dicks: The Musical” — nobody’s idea of a retread — may be the most demented riff on a familiar story yet. The film, which A24 recently released in theaters, has been called the most gonzo movie of the year. It’s lewd, ridiculous and surreal. Hanna-Barbera was an inspiration.

Megan Thee Stallion plays the boys’ boss. A disembodied part of their mother’s (Megan Mullally) female anatomy is a prominent character. A pair of monstrous pets kept by the boys’ father (Nathan Lane) named the Sewer Boys have surprisingly integral roles. Director Larry Charles calls it “the ultimate anti-AI movie.”

For even for the adventurous A24, “Dicks: The Musical” is a test of just how far the specialty studio can push the envelope. It’s especially notable, too, for a big-screen comedy landscape that has been moribund for years. Few comedies are released theatrically, and most of the ones that are timidly stick to familiar territory. But “Dicks: The Musical,” a freewheeling queer cult- favorite-to-be, is a gleefully tasteless bid to break free of comedy doldrums.

“I sometimes miss comedies like that were just like: This is dumb, and we’re going to do a bunch of jokes,” says Sharp. “We just tried to make our own favorite movie. It’s just sort of the movie we wish existed.”

“Dicks: The Musical” made its raucous premiere at the Toronto International Film Festival’s midnight program in September. The movie is derived from a 40-minute sketch show that Sharp and Jackson began performing at New York’s Upright Citizens Brigade Theatre in 2014. They used “The Parent Trap” as a template in part simply because its one-on-one scenes worked well for a two-man show. They start off playing aggressively heterosexual business bros.

“We never wanted it to feel like parody. It was more using it as a trope,” says Sharp. “ ‘The Parent Trap’ now is basically ‘The Odyssey.’ It’s a form we all know.”

But while “The Parent Trap” (the 1961 original and its 1998 remake) celebrates the reunion of a nuclear family, “Dicks: The Musical” is an outlandishly bizarro hard-R fantasia that delights in transgressing gender roles, moviemaking rules, basic decency — whatever you got.

“It’s certainly queer, but we always talked about it as being queer in the way of just being able to push in a lot of different directions,” says Sharp. “We just like the idea that we can be sort of off-leash and be absurdist and stupid and silly and foul and profane and broad.”

Charles, a writer on “Seinfeld” and director of “Curb Your Enthusiasm” and “Borat,” has long sought out original comic voices. After seeing the UCB show and reading a draft of Jackson and Sharp’s script, Charles sensed, he says, “If I could trick everybody, we could make this movie.”

“To me, they’re like a gay Abbott and Costello,” says Charles. “The possibilities of what they can do together are boundless. Like Sacha (Baron Cohen), they’re undiscovered treasures that the audience is waiting for and doesn’t even realize it.”

From the beginning, Charles wanted to preserve as much of the live-wire nature of the show. Nothing was too much, too silly or too grotesque. Jokes would fly at “Blazing Saddles” speed.

“There’s a tentativeness around comedy right now,” Charles says. “People maybe want to go for a bigger laugh, but they’re afraid they’re going to offend too many people. And there’s often too many people involved in the decision making of what’s funny.”

“Dicks: The Musical,” though, was principally a brain trust of Sharp, Jackson and Charles. (Producer Kori Adelson with Chernin Entertainment, who first approached the duo about a movie adaptation, was also integral.)

As others joined, they had to be prepared for just what they were stepping into. Megan Thee Stallion — whose high-octane performance has some calling for a best song Oscar nomination — spoke to Jackson and Sharp about the business her character runs in the film — a sales company for “Vroomba” parts.

“She was like, ‘So what do we do again?’ ” Sharp recalls. “We’d explain it to her, and she was like, ‘Oh so it’s dumb.’ We were like, ‘Yeah, it’s really dumb.’ ”

Yang had seen the UCB show. “I remember from go it was like: I love this,” he says. As Jackson and Sharp developed the movie, they carved out the role of God, as narrator, for Yang. As he read the screenplay, Yang could tell this wasn’t exactly a traditional deity.

“That was all good raw material for me to be like, ‘Oh, he’s God, but he’s going to do drugs and not be super invested in the story and make comments like, ‘That number was fierce,’ ” says Yang.

There are risks, of course, in total irreverence. Yang’s show-stopping final number isn’t one likely to be cheered by some religious conservatives. At the film’s premiere, Sharp said during that scene’s shoot, Mullally walked over to him and Jackson and said, “You guys are going to get death threats. ... We’re all going to get death threats.”

“I really love the idea of trying to get that audience to laugh almost like a horror movie,” he adds. “I want people to scream until they’re laughing.”

The joy of “Dicks: The Musical” is how it doesn’t take anything — most of all itself — even the slightest bit serious. The movie deconstructs along the way. One moment catches an actor breaking. One shot pulls back to reveal the Dolly track it. A New York street scene zooms out to show the surrounding hills of Los Angeles. What is this, exactly, you might wonder.

“It’s its own world,” says Sharp.