Review request 6985422: flush the output streams before OnError commands

David Holmes David.Holmes at
Thu Sep 16 16:57:05 PDT 2010

Vladimir Kozlov said the following on 09/17/10 03:12:
> When the VM aborts, flush the output streams before
> OnError commands are processed. Log files will not be
> flushed if SuppressFatalErrorMessage is used to avoid
> all post fatal error processing.

Why was the ostream_abort() removed from the os::shutdown() path?

In the existing code we have:

  -> os::abort()
     -> os::shutdown()
        -> ostream_abort()

and you've moved ostream_abort() into report_and_die(), but there are 
other exit paths that also call os::shutdown() and will no longer call 

-> vm_shutdown()
     -> os::shutdown()

Also with this move you need to fix this comment in ostream.cpp:

// ostream_abort() is called by os::abort() when VM is about to die.
void ostream_abort() {

Why not just add explicit flush() calls where needed?

David Holmes

> Contributed-by: rasbold at

More information about the hotspot-dev mailing list