The basic gist is that stress can be a good thing and a motivator if it is not overdone.
The problems arise with chronic stress. "Fear becomes conditioned and habitual." When you enter this mode it is VERY hard to break out of it. You begin to worry about every imaginable boogeyman and you'll have no luck getting into a focused state, which is necessary to write any type of good code.
As much as it would be a wonderful asset, I do not perform my best work while under loads of stress. When I'm programming, I generally need time to think through a problem to come up with a good long term solution.
When the stress of a very close deadline looms I tend to throw out whatever code will suffice just to meet the deadline and end the stressful situation. I had a bad project a couple of years ago where the deadlines were already extremely tight and the client was allowed to add all sorts of change requests to those deadlines. This resulted in LOTS of long hours and poorly implemented ideas.
Overall, the biggest overlooked problem facing software developers is "the interruption." It comes in many shapes and sizes and is extremely unpredictable. It seems to be a bigger issue in what is considered to be an "open working environment," where everyone is visible merely sitting at their desk working.
This is an invitation for anyone to walk up to you and break your concentration at any time. The only method of fighting this seems to be wearing headphones, even if they are turned off...and even that is only moderately effective.
For the best productivity from developers, try out what is going on at Glitch Software. For most businesses this is a pipe dream, but I believe it would make a BIG difference in the ability of developers to deliver quality products.
"A programmer is most productive with a quiet private office, a great computer, unlimited beverages, an ambient temperature between 68 and 72 degrees (F), no glare on the screen, a chair that’s so comfortable you don’t feel it..."
Many developers instead must try to focus through various project status meetings in their sitting area, conference calls right by their desks, and project management people who need updates multiple times per hour.
Imagine if we had the ability to focus on a problem and actually figure it out.