People who are sleep-deprived often report getting a "second wind" where they suddenly wake up and feel great — though they are still too fatigued to do any major problem-solving. A group of researchers have discovered there's a good reason for this. Sleep deprivation floods your brain with dopamine, the very same hormone that amphetamines like crystal meth shoot into your neural receptors. So basically you don't need that speed to stay awake. You just need to, well, stay awake. The researchers speculate that amphetamines emulate the body's natural response to sleeplessness, which is to boost your alertness with extra dopamine. Speed tricks your body into thinking it needs a boost after a sleepless night. But there's a good reason why people don't get addicted to staying up all night. According to Science Daily:

The rise in dopamine following sleep deprivation may promote wakefulness to compensate for sleep loss. "However, the concurrent decline in cognitive performance, which is associated with the dopamine increases, suggests that the adaptation is not sufficient to overcome the cognitive deterioration induced by sleep deprivation and may even contribute to it," said study author [Dr. Nora] Volkow.

So I guess the message is that if you want to stay up all night, and keep that cognitive performance going, you'll have to turn to drugs. Or maybe you could just get some sleep. One Sleepless Night Increases Dopamine in the Human Brain [Science Daily]