Talking with the director of ''The 40 Year-Old Virgin'' -- Judd Apatow tells us about the hope, obsession, and endless performance anxiety he experienced in bringing his debut film to life

The chest-waxing scene is golden. The speed-dating bit kills. But with just a month to go until his feature directorial debut, The 40 Year-Old Virgin, opens in theaters, Judd Apatow is still sitting in a Santa Monica editing room at 10 in the morning, sweating the small stuff.

The buzz on Virgin — a smashup of the horndog humor of Wedding Crashers and the angsty soul of Sideways, about a middle-aged nerd named Andy Stitzer (Steve Carell) who’s never gotten laid — has been overwhelmingly positive. But an offbeat, very R-rated comedy about a celibate doofus’ quest, aided by three overeager co-workers (Paul Rudd, Seth Rogen, Romany Malco), to woo a single mom (Catherine Keener) may not have the easiest time making it past second base at the box office. So Apatow is going over every frame of the film again, listening to audio recordings of test audiences’ laughter, trying to figure out which moments could use extra love. ”The ‘f— buddy’ line doesn’t get a laugh,” he says to editor Brent White. ”But is that a good silence or a bad silence?” He groans. ”After you’ve watched the movie a hundred times, your brain is just mush.”

Inasmuch as the comedy world has an inner circle, Apatow is one of its most respected members. As a writer and producer in TV and film, he’s worked with most of the people who’ve made you laugh since the Clinton years, including Jim Carrey, Garry Shandling, Jack Black, Ben Stiller, and Owen Wilson. His résumé includes some of the most beloved (by critics, at least) TV comedies in recent memory — most famously, the brilliant but short-lived high school trauma-rama Freaks and Geeks — along with films like last year’s Will Ferrell comedy Anchorman. To Ferrell, Apatow is ”a superstar”; Stiller calls him ”one of the funniest people I know.” For all that, as a film director, Apatow is just now, at 37, losing his virginity.

The truth is, he would probably be stressed even without a movie opening. It’s just the way he’s wired: The pathways in his brain for anxiety and humor are irremediably tangled. Soon after Virgin opens, he’s supposed to attend his 20th high school reunion, but he hasn’t decided if he’s going. ”I’ve been so stressed out from work over the last 10 years that my memory is in shreds and I’m afraid it will just be a series of me calling people ‘big guy’ and not remembering that they even existed. I’m like a pothead without the pot. It’s from staying up all night hoping they don’t force you to cast the wrong guy or something. It’s terrible.”

Before he can even contemplate that, though, Apatow needs to finish Virgin and launch it into theaters. He smiles wearily as he thinks about what’s to come. ”This experience has been somewhat perfect to this point,” he says, ”which always means a tragic end.”

For a man so adept at mining comedy from the plight of the underdog, it’s somehow fitting that Apatow is most famous for his failures. His career history reads like a sort of greatest-hits of misses. The groundbreaking 1992 sketch-comedy series The Ben Stiller Show, which he co-wrote and executive-produced, won an Emmy and wide critical acclaim but was canceled by Fox after only 12 episodes. His first big movie, 1996’s black comedy The Cable Guy, which he produced (and on which he met his wife, actress Leslie Mann), was reviled by critics and battered at the box office, though it’s gained some respect in recent years. Freaks and Geeks, which he executive-produced for NBC in 1999, couldn’t make it past 15 episodes, despite some of the most rapturous reviews in recent TV history. The 2001 college campus comedy Undeclared was euthanized after 17 episodes, again after critical praise. (The series has just been released on DVD.)