JDK-8343953 : Test jdk/jfr/threading/TestDeepVirtualStackTrace.java fails with Parallel/Serial GC
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 24
  • Priority: P4
  • Status: New
  • Resolution: Unresolved
  • Submitted: 2024-11-11
  • Updated: 2024-11-11
Related Reports
Relates :  
Description
Testing event: test.Deep
=============================
Emitted Deep event
test.Deep {
  startTime = 11:35:55.055 (2024-11-11)
  eventThread = "" (javaThreadId = 19, virtual)
  stackTrace = [
    jdk.jfr.threading.TestDeepVirtualStackTrace.deepevent(int) line: 70
    jdk.jfr.threading.TestDeepVirtualStackTrace.deepevent(int) line: 74
    jdk.jfr.threading.TestDeepVirtualStackTrace.deepevent(int) line: 74
    jdk.jfr.threading.TestDeepVirtualStackTrace.deepevent(int) line: 74
    jdk.jfr.threading.TestDeepVirtualStackTrace.deepevent(int) line: 74
    ...
  ]
}



Testing event: jdk.ObjectAllocationOutsideTLAB
=============================
Emitted ObjectAllocationOutsideTLAB event
----------System.err:(15/1073)----------
java.lang.RuntimeException: No event found in virtual thread: expected false, was true
	at jdk.test.lib.Asserts.fail(Asserts.java:691)
	at jdk.test.lib.Asserts.assertFalse(Asserts.java:518)
	at jdk.jfr.threading.TestDeepVirtualStackTrace.assertStackTrace(TestDeepVirtualStackTrace.java:104)
	at jdk.jfr.threading.TestDeepVirtualStackTrace.testNativeEvent(TestDeepVirtualStackTrace.java:78)
	at jdk.jfr.threading.TestDeepVirtualStackTrace.main(TestDeepVirtualStackTrace.java:60)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
	at java.base/java.lang.reflect.Method.invoke(Method.java:567)
	at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
	at java.base/java.lang.Thread.run(Thread.java:1576)

Options:     -Dtest.java.opts='-XX:+UseSerialGC -XX:+UnlockExperimentalVMOptions -XX:+UseCompactObjectHeaders' 
Comments
I was under the impression it was -XX:+UseCompactObjectHeaders that was now causing this failure to trigger. Has something else changed here to cause this failure?
11-11-2024

The problem is that test tries to provoke jdk.ObjectAllocationOutsideTLAB however GC can increase TLAB and don't generate outside of TLAB even for the allocated = new Object[10_000_000]; Test might be updated to expect jdk.ObjectAllocationOutsideTLAB or jdk.ObjectAllocationInNewTLAB or/and tries to allocate several times.
11-11-2024