Bernard (Jim Rash) and Huey (David Koechner) reconnect as middle-aged men surveying their lives, in the film, “Bernard and Huey.” (Bugeater Films)

WHEN HOLLYWOOD heads to Washington to discover and decode treasured documents, it’s not always the stuff of Jerry Bruckheimer-produced fiction.

In this case, the real-life plot twist has the wry spin of a Jules Feiffer work.

Dan Mirvish, the Slamdance festival co-founder and “Between Us” writer, had read that Feiffer, the Pulitzer-winning cartoonist and Obie-winning playwright, had several screenplays that had never been produced. That piqued Mirvish’s curiosity — but he had no idea that would launch him on a three-year quest for the one he most wanted, which would become the new movie, “Bernard and Huey.”

More than a half-century earlier, Feiffer was writing his iconic Village Voice comic strip — in the first year of the feature’s 43-year run — when he hit upon the creation of an oddball pairing of characters. Bernard was a nebbishy intellectual who tried to speak with college-aged women on a high-minded level, generally getting nowhere; Huey was the mumbling, leather-jacketed Neanderthal who offered no such conversation — yet these same academic women fell for him.

Feiffer says he created his Bernard character to be similar to writer Robert Benchley’s incisively comic persona of the bumbling, ineffectual man, but with one cultural difference: “He’s circumcised.”

“He was always having trouble with women in those early strips,” Feiffer, 89, tells The Washington Post’s Comic Riffs. “And then I went to one of these Village parties at the time, and there were all of these absolutely gorgeous Sarah Lawrence, Vassar and Bennington girls” — young women, he says, who preferred this nonintellectual guy who walked into the room — a “muscled goon in blue jeans who spoke in ‘dem’s and dose’s’.”

“He was an actor doing his Brando, and it worked” with these women, Feiffer says. “And that became Huey.”

Because “they wanted the bad boy and not me,” the artist continues, Bernard and Huey increasingly appeared in his strip. “That was my rage.”

Fast-forward to the 1980s, when Feiffer, in creating a feature for Playboy magazine, decided to update Bernard and Huey. Only now, instead of college-age men on the make, they were older, if not always wiser.

“These were two over-the-hill guys who had . . . graduated some 30 years later in the pages of Playboy as out-of-shape, middle-aged men hitting on young women,” Feiffer says of how his characters satirized Playboy’s target audience. “In other words, the unspoken real Playboy reader, as opposed to the fantasy figure. And it was about them — all the B.S., all the striving, all the sense of being left behind and left out in the current world.”

Jules Feiffer’s cartoon characters, Bernard and Huey. (Jules Feiffer)

In the mid-’80s, Emmy-nominated producer Michael Brandman (“The Heidi Chronicles,” “American Playhouse: Into the Woods”) believed that Bernard and Huey were worthy of a series, so he persuaded Feiffer to adapt his characters for television.

“I figured out a plot and a story that was never in the original [cartoons] about Huey and his family and his daughter — all sorts of things that were all new,” says Feiffer, who today relishes writing a series of noir graphic novels (“Kill My Mother”).

“I dramatized it. Michael loved it. He sold it to Showtime. Showtime loved it. Showtime changed hands. The new Showtime hated it. And Michael couldn’t find any other place to place it.”

So that script sat dormant for decades — eventually published in Scenario magazine among other unproduced screenplays — till Mirvish came calling.

Dan Mirvish, director of “Bernard and Huey.” (Bugeater Films)

Mirvish and his team were interested in a “Bernard and Huey” script, but Feiffer had gotten divorced and moved to the Hamptons, and had no idea where he might have a copy.

“It took a year and a half for us to track down a copy of the script to the Academy of Motion Pictures library, in Scenario magazine,” Mirvish says. “But then Jules said that might have been abridged. But his assistant, agent and lawyer were all dead. So then we tracked down his old producer, Michael Brandman, who searched his archives and found a printed script.”

“Several months later, I realized one reason Jules couldn’t find his archives is that he’d donated some of them to the Library of Congress,” he continues. “So I sent my buddy Mike Shubbuck, who lives in D.C., to the Library of Congress.”

There, the final piece of the screenplay puzzle was unlocked. “He found the original handwritten copy of the script on yellow legal pads — which included doodles of the characters,” says Mirvish, noting that Feiffer never learned to type.

They weren’t quite ready to roll, though.

To get the project off the ground, Mirvish and his fellow producers were able to raise almost $30,000 on Kickstarter.

They cast actor and Oscar-winning writer Jim Rash, David Koechner, Mae Whitman, Sasha Alexander, Richard Kind and Nancy Travis.

Jules Feiffer. (Bugeater Films)

They were able to create an intimate, winning film that would make a great double feature with another 2017 release based on the work of another graphic novelist: “Wilson,” starring Woody Harrelson as a middle-aged man struggling not to get left behind, as created by Daniel Clowes.

(“Bernard and Huey” is playing in theaters across the country, and locally at the AMC Hoffman Center 22 in Alexandria, Va. It is also available on iTunes and other VOD.)

“Jules is such a uniquely talented and influential figure in America that it was a tremendous privilege to help bring his beloved characters to life from a script that I think is both timeless and timely,” says Mirvish of Feiffer, who previously received Writers’ Guild screenplay nominations for “Carnal Knowledge” (directed by Mike Nichols) and “Little Murders” (directed by Alan Arkin).

“I’d like to think I share a similar satiric and subversive sensibility to Jules, so the script was a great fit for me, and I couldn’t have found a better screenwriter alive to write such incredible dialogue,” Mirvish adds. “Also, after spending three years hunting down the script . . . and spending so much time with Jules, I felt I owed it to him, and to his fans, to bring the film to light.”

This year, the screenplay was a jury prize winner at the Manchester International Film Festival.

“I was very happy that I let him do it,” Feiffer says of Mirvish. “I was happy that I involved myself, and I was totally surprised by the results, which are as good an adaptation of my work as I’ve ever seen. In some ways — a very different way — it’s in a league with ‘Carnal Knowledge.’ ”

Which is, of course, just about the highest praise he could offer.

Read more:

The ‘godfather of the alties’ finds he’s a new man since leaving Manhattan

How sketching a dying father led Daniel Clowes to his quirky film ‘Wilson’