LogCompilation and OnError

John Rose john.r.rose at oracle.com
Fri Sep 3 14:53:15 PDT 2010

On Sep 3, 2010, at 2:48 PM, Chuck Rasbold wrote:

> Currently, if the VM aborts, LogCompilation files are flushed and closed as a result of a call to ostream_abort() in os::shutdown().
> I'd like the LogCompilation files flushed a little earlier, ideally, immediately before OnError commands are processed in vmError::report_and_die().
> Has this been investigated before?  Any concerns about moving the call to ostream_abort from the os specific files into vmError.cpp?

I don't think so.  It seems like flushing those buffers is a low-risk thing to do, and so could be done earlier during crash dumping.

The thing to avoid is causing an already-crashing JVM to crash even more, by trying to traverse broken data structures.  There is some logic called "STEP" in vmError.cpp which tries each dump phase at most once.  The buffer flushing (even though it is not likely to fail) should probably be covered by that logic.

-- John

More information about the hotspot-compiler-dev mailing list