A snail walks into a police station and says, “Two turtles attacked me!” The desk sergeant opens a file and says, “Tell me exactly what they did to you.” The snail says, “I don’t remember, it all happened so fast.”

(Knopf)

This is easily the best inoffensive joke in Israeli writer David Grossman’s brilliant, blistering new novel. “A Horse Walks Into a Bar” comprises a single disastrous performance by the stand-up comic Dovaleh G in a nightclub in Netanya, north of Tel Aviv. Although never letting up on the crude sex jokes, some of which made me laugh, Dovaleh lampoons Palestinians, West Bank settlers and what he calls “God’s whole Holocaust initiative.” His father was the survivor of an extended family that was exterminated at Auschwitz after passing through the laboratory of Nazi researcher Josef Mengele. “You could say, in fact, that in his own special way he was like our family doctor.”

I kind of laughed at that one, too.

The main purpose of Dovaleh’s act is to review the highlights of his miserable 57-year existence — his unhappy parents, his outcast childhood, his divorces, his loneliness — as he lacerates himself and mocks individual members of the audience, some abhorrently. There are several good jokes, but the performance is mostly unfunny. He’s heckled. The nightclub gradually empties out. Those left are giving in to “the temptation to look into another man’s hell.”

One guest is his childhood friend Avishai, a retired district judge who hadn’t seen Dovaleh since summer camp. Avishai didn’t even recognize Dovaleh’s name when the comedian called to invite him to the club. Tending to his own loneliness, still mourning his wife’s early death, he demurred. Dovaleh pleaded with him to come. Avishai hates the show at first, but in the course of the evening a fresh connection is forged between him and the man onstage. He stays to the very end. So will another visitor from the past, uninvited, a female dwarf whom the comedian now derides as “Thumbelina.”

Late in the show, Avishai realizes that Dovaleh is dying — and not only in the sense that the audience isn’t laughing.

Grossman masterfully weaves several complex strands of narrative. First there are Dovaleh’s stories, particularly a single story that takes most of the book to unfold and aims at the heart of his self-loathing. The comedian interrupts this anecdote to tell other stories, to insult guests demanding more humor, to pacify them with a few jokes and then to further insult them. Translator Jessica Cohen turns the performance into fluent, American-style patter, bad-a-bing bad-a-boom.

Author David Grossman, ( Michael Lionstar)

Meanwhile, in the spaces between Dovaleh’s riffs, the retired judge recalls his late wife and his brief childhood friendship with the comedian. Avishai sees in advance that he tangentially figures in the principal story, the traumatic event that has haunted Dovaleh’s life.

It’s a shameful incident, but really a small one within the greater scheme of a man’s tenure on Earth. Part of the work of adulthood is forgiving your adolescent self for your ignorance, your bad judgment and your wrong thoughts. Dovaleh can’t do it. In the nightclub’s spotlight, “a fifty-seven-year-old boy is reflected out of a fourteen-year-old man.”

Dovaleh G says he was born Dov Greenstein, a name that echoes the author’s. Dov’s an alter ego, or a suggestion of the man David Grossman could have been if he were not the distinguished, urbane author of 13 previous morally sensitive works of fiction and nonfiction, including his acclaimed 2008 novel, “To the End of the Land.” The wild and coarse Dovaleh is Grossman’s Hyde, his Portnoy — unable to repress or restrain the humiliated, fearful and morbid parts of his nature that Grossman has turned into literature. At one point in the monologue, Dovaleh slaps his face hard. He later punches himself, drawing blood. He is, however, no less an artist than Grossman.

Something transactional is at work in this artistry. Avishai observes between comic and audience a “murky sense of partnership that prickles deep in our gut and stirs up a sticky, messy pleasure both sickening and alluring.” The relation also holds true between a literary author who reveals the darker elements of human nature and the reader who enjoys the disclosure. We laugh at least at some of Dovaleh’s ugly comments. After a lifetime of writing, Grossman is acknowledging that by entertaining his readers, he, too, has implicated them in his conceits, his failings and his cruelties.

“A Horse Walks Into a Bar” is a concise novel, quick reading. With Dovaleh, Grossman has created a character who’s captivating and horrific and a stand-up routine that’s disgusting and authentically human. I can hardly say how the book achieves its bewitching effects. It all happened so fast.

Ken Kalfus’s most recent book is a collection: “Coup de Foudre: A Novella and Stories.”

On March 2 at 7 p.m., David Grossman will speak at Sixth & I Historic Synagogue, 600 I St. NW, Washington, DC 20001. For tickets, call 877-987-6487.

A HORSE WALKS INTO A BAR

By David Grossman

Translated from the Hebrew by Jessica Cohen

Knopf. 194 pp. $25.95