>>740As best I can tell, the LD
50 is around 500mg/kg in rats, and probably somewhat less in humans. Assuming you have average (~80kg) body mass, in theory it would take 800 pills (40g) to have a 50% chance of killing you; to have any sense of certainty you'd probably want at least twice that.
In reality, no matter how many pills you take, the most likely result is just some combination of throwing up, passing out, having a seizure and having to get your stomach pumped. Swallowing pills is extremely ineffective as a suicide method and rarely works (~2% success rate). You'd have much better luck with firearms or hanging, so long as you don't mind the risk of permanent brain damage.
More information on diphenhydramine toxicity
here; more information on success rates of different suicide methods
here. Hope that helps.