RFR: 8327176: UnreferencedExecutor.java can fail on libgraal with -Xcomp
Doug Simon
dnsimon at openjdk.org
Tue Mar 19 11:18:28 UTC 2024
The `java/util/concurrent/Executors/UnreferencedExecutor.java` test can fail when run on libgraal and `-Xcomp` is specified. The problem is that libgraal in `-Xcomp` temporarily causes some extra memory pressure (probably due to [JDK-8310218](https://bugs.openjdk.org/browse/JDK-8310218)) which can cause recoverable OOMEs to occur (memory is recovered when the relevant libgraal compilations complete). It also seems related to async threads used for cleaning weak references when using G1 or ZGC as I cannot reproduce the failure under `-XX:+UseSerialGC`.
Installing a global `Thread.UncaughtExceptionHandler` that ignores `OutOfMemoryError`s resolves the problem.
-------------
Commit messages:
- ignore recoverable OOMEs
Changes: https://git.openjdk.org/jdk/pull/18098/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=18098&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8327176
Stats: 23 lines in 1 file changed: 23 ins; 0 del; 0 mod
Patch: https://git.openjdk.org/jdk/pull/18098.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/18098/head:pull/18098
PR: https://git.openjdk.org/jdk/pull/18098
More information about the core-libs-dev
mailing list