As a Wing Chun guy I do a lot of
chain punching. That's fast continuous "machine gun" punching. In warm ups we will do 200-500, and it's like jogging. You try to relax as much as possible and breath naturally, like Jobo said.
However, in application or sparring you don't just unload with a continuous flurry of dozens of punches. That's like a soldier running toward the enemy unleashing a continuous, non-stop stream of automatic fire. He won't hit much and he'll run out of ammo very quickly. Instead the soldier uses short targeted bursts of fire. Similarly in Wing Chun we use short targeted bursts of chain punches or other combinations.
In this situation, I find myself exhaling for the short duration of each burst and inhaling in the moments in between. I would use a bit more air for a more powerful or committed punch, but generally I would not empty my lungs completely - I like to have a little air left in reserve.
Now regarding some of Jobo's comments, I agree that you
can inhale when punching if necessary. But non-scientifically speaking, I don't feel that's optimal. In most of the physical activities I've ever done, any sudden exertion of force involving the contraction of major muscle groups is accompanied by a short forceful exhalation. And that's what I do when punching.
Besides, if you
inhale when punching, people might think your punches
suck.