eclipse-openj9 / openj9

Eclipse OpenJ9: A Java Virtual Machine for OpenJDK that's optimized for small footprint, fast start-up, and high throughput. Builds on Eclipse OMR (https://github.com/eclipse/omr) and combines with the Extensions for OpenJDK for OpenJ9 repo.
Other
3.27k stars 721 forks source link

OpenJDK java/util/concurrent/tck/JSR166TestCase security-manager timed out waiting for thread to terminate #19082

Open pshipton opened 6 months ago

pshipton commented 6 months ago

https://openj9-jenkins.osuosl.org/job/Test_openjdk22_j9_sanity.openjdk_aarch64_linux_Nightly_testList_0/23 jdk_util_1 java/util/concurrent/tck/JSR166TestCase.java#security-manager

23:17:04  STARTED    LockSupportTest::testParkNeg_parkUntil 'testParkNeg_parkUntil'
23:17:04  junit.framework.AssertionFailedError: timed out waiting for thread to terminate, thread=Thread[#1086,Thread-361,5,jsr1666TestThreadGroup], state=TIMED_WAITING
23:17:04  ------ stacktrace dump start ------
23:17:04  "main" prio=5 Id=2 WAITING
23:17:04    at java.base@22-internal/java.lang.Object.waitImpl(Native Method)
23:17:04    at java.base@22-internal/java.lang.Object.wait(Object.java:255)
23:17:04    at java.base@22-internal/java.lang.Object.wait(Object.java:221)
23:17:04    at java.base@22-internal/java.lang.Thread.join(Thread.java:2069)
23:17:04    at java.base@22-internal/java.lang.Thread.join(Thread.java:2145)
23:17:04    at app//com.sun.javatest.regtest.agent.MainWrapper.main(MainWrapper.java:85)
23:17:04  "JIT Compilation Thread-000" prio=10 Id=4 RUNNABLE
23:17:04  "JIT Compilation Thread-001 Suspended" prio=10 Id=5 RUNNABLE
23:17:04  "JIT Compilation Thread-002 Suspended" prio=10 Id=6 RUNNABLE
23:17:04  "JIT Compilation Thread-003 Suspended" prio=10 Id=7 RUNNABLE
23:17:04  "JIT Compilation Thread-004 Suspended" prio=10 Id=8 RUNNABLE
23:17:04  "JIT Compilation Thread-005 Suspended" prio=10 Id=9 RUNNABLE
23:17:04  "JIT Compilation Thread-006 Suspended" prio=10 Id=10 RUNNABLE
23:17:04  "JIT Diagnostic Compilation Thread-007 Suspended" prio=10 Id=11 RUNNABLE
23:17:04  "JIT-SamplerThread" prio=10 Id=12 TIMED_WAITING
23:17:04  "IProfiler" prio=5 Id=13 RUNNABLE
23:17:04  "Concurrent Mark Helper" prio=1 Id=14 RUNNABLE
23:17:04  "Finalizer thread" prio=5 Id=15 RUNNABLE
23:17:04  "GC Worker" prio=5 Id=16 RUNNABLE
23:17:04  "GC Worker" prio=5 Id=17 RUNNABLE
23:17:04  "GC Worker" prio=5 Id=18 RUNNABLE
23:17:04  "Attach API update file access time" prio=5 Id=21 TIMED_WAITING
23:17:04    at java.base@22-internal/java.lang.Thread.sleepImpl(Native Method)
23:17:04    at java.base@22-internal/java.lang.Thread.sleepNanos(Thread.java:498)
23:17:04    at java.base@22-internal/java.lang.Thread.sleep(Thread.java:529)
23:17:04    at java.base@22-internal/openj9.internal.tools.attach.target.AttachHandler$1.run(AttachHandler.java:345)
23:17:04  "Attach API wait loop" prio=10 Id=22 RUNNABLE
23:17:04    at java.base@22-internal/openj9.internal.tools.attach.target.IPC.waitSemaphore(Native Method)
23:17:04    at java.base@22-internal/openj9.internal.tools.attach.target.CommonDirectory.waitSemaphore(CommonDirectory.java:264)
23:17:04    at java.base@22-internal/openj9.internal.tools.attach.target.WaitLoop.waitForNotification(WaitLoop.java:66)
23:17:04    at java.base@22-internal/openj9.internal.tools.attach.target.WaitLoop.run(WaitLoop.java:157)
23:17:04  "MainThread" prio=5 Id=23 RUNNABLE
23:17:04    at java.management@22-internal/com.ibm.java.lang.management.internal.ThreadMXBeanImpl.dumpAllThreadsImpl(Native Method)
23:17:04    at java.management@22-internal/com.ibm.java.lang.management.internal.ThreadMXBeanImpl.dumpAllThreadsCommon(ThreadMXBeanImpl.java:693)
23:17:04    at java.management@22-internal/com.ibm.java.lang.management.internal.ThreadMXBeanImpl.dumpAllThreads(ThreadMXBeanImpl.java:675)
23:17:04    at app//JSR166TestCase.dumpTestThreads(JSR166TestCase.java:1229)
23:17:04    at app//JSR166TestCase.threadRecordFailure(JSR166TestCase.java:859)
23:17:04    at app//JSR166TestCase.threadFail(JSR166TestCase.java:933)
23:17:04    at app//JSR166TestCase.awaitTermination(JSR166TestCase.java:1718)
23:17:04    at app//JSR166TestCase.awaitTermination(JSR166TestCase.java:1732)
23:17:04    at app//LockSupportTest.testParkNeg(LockSupportTest.java:403)
23:17:04    at app//LockSupportTest.testParkNeg_parkUntil(LockSupportTest.java:389)
23:17:04    at java.base@22-internal/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
23:17:04    at java.base@22-internal/java.lang.reflect.Method.invoke(Method.java:586)
23:17:04    at app//junit.framework.TestCase.runTest(TestCase.java:177)
23:17:04    at app//JSR166TestCase.runTest(JSR166TestCase.java:406)
23:17:04    at app//junit.framework.TestCase.runBare(TestCase.java:142)
23:17:04    at app//JSR166TestCase.runBare(JSR166TestCase.java:397)
23:17:04    at app//junit.framework.TestResult$1.protect(TestResult.java:122)
23:17:04    at app//junit.framework.TestResult.runProtected(TestResult.java:142)
23:17:04    at app//junit.framework.TestResult.run(TestResult.java:125)
23:17:04    at app//junit.framework.TestCase.run(TestCase.java:130)
23:17:04    at app//junit.framework.TestSuite.runTest(TestSuite.java:241)
23:17:04    at app//junit.framework.TestSuite.run(TestSuite.java:236)
23:17:04    at app//junit.framework.TestSuite.runTest(TestSuite.java:241)
23:17:04    at app//junit.framework.TestSuite.run(TestSuite.java:236)
23:17:04    at app//org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:90)
23:17:04    at app//org.junit.runner.JUnitCore.run(JUnitCore.java:137)
23:17:04    at app//org.junit.runner.JUnitCore.run(JUnitCore.java:115)
23:17:04    at app//org.junit.vintage.engine.execution.RunnerExecutor.execute(RunnerExecutor.java:42)
23:17:04    at app//org.junit.vintage.engine.VintageTestEngine.executeAllChildren(VintageTestEngine.java:80)
23:17:04    at app//org.junit.vintage.engine.VintageTestEngine.execute(VintageTestEngine.java:72)
23:17:04    at app//org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:147)
23:17:04    at app//org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:127)
23:17:04    at app//org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:90)
23:17:04    at app//org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:55)
23:17:04    at app//org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:102)
23:17:04    at app//org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:54)
23:17:04    at app//org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114)
23:17:04    at app//org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86)
23:17:04    at app//org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86)
23:17:04    at app//com.sun.javatest.regtest.agent.JUnitRunner.runWithJUnitPlatform(JUnitRunner.java:142)
23:17:04    at app//com.sun.javatest.regtest.agent.JUnitRunner.main(JUnitRunner.java:95)
23:17:04    at app//com.sun.javatest.regtest.agent.JUnitRunner.main(JUnitRunner.java:61)
23:17:04    at java.base@22-internal/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
23:17:04    at java.base@22-internal/java.lang.reflect.Method.invoke(Method.java:586)
23:17:04    at app//com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
23:17:04    at java.base@22-internal/java.lang.Thread.run(Thread.java:1582)
23:17:04  "ClassByNameCache Reaper" prio=5 Id=455 WAITING
23:17:04    at java.base@22-internal/java.lang.Object.waitImpl(Native Method)
23:17:04    at java.base@22-internal/java.lang.Object.wait(Object.java:255)
23:17:04    at java.base@22-internal/java.lang.Object.wait(Object.java:221)
23:17:04    at java.base@22-internal/java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:137)
23:17:04    at java.base@22-internal/java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:109)
23:17:04    at java.base@22-internal/java.io.ClassByNameCache$Reaper.run(ClassByNameCache.java:232)
23:17:04    at java.base@22-internal/java.lang.Thread.run(Thread.java:1582)
23:17:04  "Thread-361" prio=5 Id=1086 TIMED_WAITING
23:17:04    at java.base@22-internal/jdk.internal.misc.Unsafe.park(Native Method)
23:17:04    at java.base@22-internal/java.util.concurrent.locks.LockSupport.parkUntil(LockSupport.java:449)
23:17:04    at app//LockSupportTest$ParkMethod$2.park(LockSupportTest.java:78)
23:17:04    at app//LockSupportTest$8.realRun(LockSupportTest.java:400)
23:17:04    at app//JSR166TestCase$CheckedRunnable.run(JSR166TestCase.java:1742)
23:17:04    at java.base@22-internal/java.lang.Thread.run(Thread.java:1582)
23:17:04  ------ stacktrace dump end ------
23:17:04  junit.framework.AssertionFailedError: timed out waiting for thread to terminate, thread=Thread[#1086,Thread-361,5,jsr1666TestThreadGroup], state=TIMED_WAITING
23:17:04    at junit.framework.Assert.fail(Assert.java:57)
23:17:04    at junit.framework.TestCase.fail(TestCase.java:223)
23:17:04    at JSR166TestCase.threadFail(JSR166TestCase.java:931)
23:17:04    at JSR166TestCase.awaitTermination(JSR166TestCase.java:1718)
23:17:04    at JSR166TestCase.awaitTermination(JSR166TestCase.java:1732)
23:17:04    at LockSupportTest.testParkNeg(LockSupportTest.java:403)
23:17:04    at LockSupportTest.testParkNeg_parkUntil(LockSupportTest.java:389)

Perhaps related to https://github.com/eclipse-openj9/openj9/issues/14752

JasonFengJ9 commented 1 month ago

JDK23 Milestone 1 build x86-64_windows(win10x86-rtp-rt8-1)

23:56:44  variation: -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache Mode150
23:56:44  JVM_OPTIONS:  -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:+UseCompressedOops -Xverbosegclog 

00:47:02  TEST: java/util/concurrent/tck/JSR166TestCase.java#security-manager

00:47:02  ------ stacktrace dump end ------
00:47:02  junit.framework.AssertionFailedError: timed out waiting for thread to terminate, thread=Thread[#1120,Thread-362,5,jsr1666TestThreadGroup], state=TIMED_WAITING
00:47:02    at junit.framework.Assert.fail(Assert.java:57)
00:47:02    at junit.framework.TestCase.fail(TestCase.java:223)
00:47:02    at JSR166TestCase.threadFail(JSR166TestCase.java:931)
00:47:02    at JSR166TestCase.awaitTermination(JSR166TestCase.java:1718)
00:47:02    at JSR166TestCase.awaitTermination(JSR166TestCase.java:1732)
00:47:02    at LockSupportTest.testParkNeg(LockSupportTest.java:403)
00:47:02    at LockSupportTest.testParkNeg_parkUntil(LockSupportTest.java:389)

00:47:02  FAILED     LockSupportTest::testParkNeg_parkUntil 'testParkNeg_parkUntil'

50x grinder jenkins restarted and the grinder was aborted, before that some iterations were successful child 0: 6 passed child 1: 5 passed child 2: 7 passed, 1 failed but different issue https://github.com/eclipse-openj9/openj9/issues/19373#issuecomment-2299565694 child 3: 6 passed child 4: 6 passed