RFR: 8343953: Test jdk/jfr/threading/TestDeepVirtualStackTrace.java fails with Parallel/Serial GC
Leonid Mesnik
lmesnik at openjdk.org
Wed Nov 13 00:39:27 UTC 2024
Test fails because it doesn't always trigger jdk.ObjectAllocationOutsideTLAB event.
Test tries to trigger jdk.ObjectAllocationOutsideTLAB by allocating
new Object[10_000_000];
array.
However, the TLAB is not limited for Parallel/Serial/Z GCs. So VM might just increase TLAB and allocate the array in new TLAB. The fix limit young generation size to ensure that TLAB of expected size can't be created and
jdk.ObjectAllocationOutsideTLAB event is always generated.
Verified by running 100 times with Parallel/Serial/ZGC on different platforms.
Using jdk.ObjectAllocationOutsideTLAB is not the signifcant for the test. The better fix would be trigger some other event with 100% guarantee assuming that this event is not triggered outside of virtual thread. But not sure I which event is the good candidate.
-------------
Commit messages:
- Test jdk/jfr/threading/TestDeepVirtualStackTrace.java fails with Parallel/Serial GC
Changes: https://git.openjdk.org/jdk/pull/22052/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=22052&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8343953
Stats: 2 lines in 1 file changed: 0 ins; 0 del; 2 mod
Patch: https://git.openjdk.org/jdk/pull/22052.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/22052/head:pull/22052
PR: https://git.openjdk.org/jdk/pull/22052
More information about the hotspot-gc-dev
mailing list