I agree performance is not a problem. But it's just weird behavior. We should flush stdout termination, anything else would have to be carefully justified - and this is not.
stdout is flushed on termination. Your code just doesn't puke a stack trace if there is an issue after main exits.
-Steve