RFR: 8364090: Dump JFR recording on CrashOnOutOfMemoryError [v3]
Erik Gahlin
egahlin at openjdk.org
Mon Jul 28 16:54:00 UTC 2025
On Mon, 28 Jul 2025 07:06:48 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
>> Yasumasa Suenaga has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Add emit_event_shutdown
>
> Looks reasonable to me. But could you please add a simple regression test? Easiest would be to modify TestCrashOnOutOfMemoryError.java - add a second `@test ` section, start the test with a different parameter that signals that you run the testee with JFR enabled, and then test for existence of the JFR dump.
> @tstuefe @egahlin
>
> Thanks for your review and advice! I added testcase in `test/jdk/jdk/jfr/event/oldobject` because this change is not only crash handler. `before_exit()` calls if OOM happens without `CrashOnOutOfMemoryError`.
Does it also happen with -XX:ExitOnOutOfMemoryError?
I'm not sure we want that. Most users, I think, want a quick exit if they have specified that option. They are not interested in having the Java heap swept to find memory leak candidates.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/26468#issuecomment-3128128908
More information about the hotspot-jfr-dev
mailing list