RFR: 8364090: Dump JFR recording on CrashOnOutOfMemoryError [v5]

Yasumasa Suenaga ysuenaga at openjdk.org
Wed Jul 30 05:16:42 UTC 2025


> JFR emergency dump would happen when OOM was thrown. However it would not contain most recent `OldObjectSample` events emitted by LeakProfiler.
> 
> I [reported this issue in past](https://mail.openjdk.org/pipermail/hotspot-jfr-dev/2019-January/000381.html), and it seems to be difficult to fix soon, and also JDK codebase has been updated in several years. It brings us to fix this issue easier than past.
> 
> So I propose again to emit the events from LeakProfiler when OOM happened.
> This change passed `jdk_jfr` tests on Linux x64 (excepts TestHeapSummaryEventPSParOld.java reported in [JDK-8364082](https://bugs.openjdk.org/browse/JDK-8364082))
> 
> Related email thread: https://mail.openjdk.org/pipermail/hotspot-jfr-dev/2025-July/008007.html

Yasumasa Suenaga has updated the pull request incrementally with one additional commit since the last revision:

  Update TestEmergencyDumpAtOOM.java

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/26468/files
  - new: https://git.openjdk.org/jdk/pull/26468/files/5ecd4e43..a20d56a7

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=26468&range=04
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=26468&range=03-04

  Stats: 58 lines in 1 file changed: 22 ins; 11 del; 25 mod
  Patch: https://git.openjdk.org/jdk/pull/26468.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/26468/head:pull/26468

PR: https://git.openjdk.org/jdk/pull/26468


More information about the hotspot-jfr-dev mailing list