If you're going to do this (and I've done it myself), be aware that it may increase the risk of blot clots (deep vein thrombosis). You're supposed to try to get up and move around every couple of hours on a long flight, and taking an Ambien or the like may mean you'll go 6-8 hours (or more) without doing that. Plus, you won't be drinking any water, which isn't healthy.
One of the best ways I've found to both increase hours slept and reduce overall stress on long flights is to buy some cheap foam earplugs and wear them the whole time. (Noise reducing headphones are great but they're bulkier, more expensive and have to be turned off during takeoff and landings.) I used to fly red-eyes fairly regularly and having a bag of those bright orange foam earplugs in the pocket of your work bag was a lifesaver.
I found what also works are the Etymotic headsets, if you are the type of person that doesn't mind the in-ear style headsets. During takeoff and landing, I leave the plug dangling from my hand and obviously visible so the flight attendants don't bother me about turning off my $music_player. One less thing to keep track of while traveling, and fills multiple purposes.
DVT is no joke on these marathon flights, glad you pointed it out to others in this thread.
Yeah, I actually use Ultimate Ears (if I remember to put them in my bag.) I've found that there are some advantages to earplugs, though - they're so cheap you can leave a dozen in your work bag (and give a pair to your travel companion if they need them) and there's no wire to worry about when you're just trying to sleep.
The risk probably depends on your age. I've flown from LAX to Hong Kong and back in business class before, and the flights leave after midnight local time. I found it no trouble to sleep for 12 hours without taking any drugs. No blood clots, no dehydration :)
Neither of us can really hope to assess the change in risk of something like DVT based on personal experience. We're talking about something that normally kills some tiny portion of travelers (1 in 100,000 passenger legs, maybe?)... if not moving around increases that risk 10x, you'd still have to do a few hundred thousand flights to know.
Edit: The annual risk of DVT apparently runs about 1 in 3,000 for the general population. So if you were a higher risk passenger (older) and flew really regularly, I could see it getting down towards say 1 in 100 annually. Even then, you'd still need decades of data to make any conclusion.
OK, but how is lying in bed on a plane different from lying in bed on the ground? (If it's the difference in air pressure, wouldn't everyone in Denver and Mexico City be dead by now?)
For one thing, when you're lying down, your feet are generally level with your heart, which makes it easier to circulate blood through your legs. Also, you're going to change position naturally while sleeping in a bed, but you're much less likely to do so when jammed into an airplane seat. Plus most people don't spend more than 8-10 hours in bed at a time, whereas DVT is primarily a big concern on long flights stretching 12-20 hours.
One of the best ways I've found to both increase hours slept and reduce overall stress on long flights is to buy some cheap foam earplugs and wear them the whole time. (Noise reducing headphones are great but they're bulkier, more expensive and have to be turned off during takeoff and landings.) I used to fly red-eyes fairly regularly and having a bag of those bright orange foam earplugs in the pocket of your work bag was a lifesaver.