JDK-8264605 : vmTestbase/nsk/jvmti/SuspendThread/suspendthrd003/TestDescription.java failed with "agent_tools.cpp, 471: (foundThread = (jthread) jni_env->NewGlobalRef(foundThread)) != NULL"
  • Type: Bug
  • Component: hotspot
  • Sub-Component: jvmti
  • Affected Version: 17
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: x86_64
  • Submitted: 2021-04-01
  • Updated: 2022-03-30
  • Resolved: 2021-11-24
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 17 JDK 18
17.0.4-oracleFixed 18 b26Fixed
Related Reports
Relates :  
Description
The following test failed in the JDK17 CI:

vmTestbase/nsk/jvmti/SuspendThread/suspendthrd003/TestDescription.java

Here's a snippet from the log file:

[4.367s][debug][thread,smr] tid=5322: Threads::remove: new ThreadsList=0x00007f86e0000d80
[4.367s][debug][thread,smr] tid=5322: ThreadsSMRSupport::free_list: threads=0x00007f86e4000e60 is freed.
[4.367s][debug][thread,smr] tid=5322: ThreadsSMRSupport::smr_delete: thread=0x00007f86ec034f30 is deleted.
The following fake exception stacktrace is for failure analysis. 
nsk.share.Fake_Exception_for_RULE_Creation: (agent_tools.cpp:471) (foundThread = (jthread) jni_env->NewGlobalRef(foundThread)) != NULL
	at nsk_lvcomplain(nsk_tools.cpp:172)
# ERROR: agent_tools.cpp, 471: (foundThread = (jthread) jni_env->NewGlobalRef(foundThread)) != NULL
#   verified JNI assertion is FALSE
# ERROR: suspendthrd003.cpp, 60: (testedThread = nsk_jvmti_threadByName(THREAD_NAME)) != NULL
#   verified assertion is FALSE
Comments
A pull request was submitted for review. URL: https://git.openjdk.java.net/jdk17u-dev/pull/293 Date: 2022-03-29 11:56:06 +0000
29-03-2022

Fix Request (17u): Should get backported for parity with 17.0.4-oracle. Skara recognizes it as clean (Problem list has different context). Test has passed.
29-03-2022

Changeset: 96fe1d0d Author: Leonid Mesnik <lmesnik@openjdk.org> Date: 2021-11-24 20:11:18 +0000 URL: https://git.openjdk.java.net/jdk/commit/96fe1d0d4d95d87950ff2ecec570a927d831746e
24-11-2021

JDK-8266130 convert Thread-SMR stress tests from counter based to time based is integrated in the jdk/jdk repo so the latest version of the test is now available directly from the repo (instead of the PR).
10-06-2021

Spotted in my jdk-17+21 stress testing: $ unzip -l jdk-17+21_linux.8264605.zip Archive: jdk-17+21_linux.8264605.zip Length Date Time Name --------- ---------- ----- ---- 15500 2021-05-07 00:30 jdk-17+21_1/failures.linux-x86_64/TestDescription.jtr.slowdebug 15496 2021-05-08 15:51 jdk-17+21_3/failures.linux-x86_64/TestDescription.jtr.fastdebug --------- ------- 30996 2 files
10-05-2021

Spotted in my jdk-17+20 stress testing: $ unzip -l jdk-17+20_linux.8264605.zip Archive: jdk-17+20_linux.8264605.zip Length Date Time Name --------- ---------- ----- ---- 15031 2021-05-01 12:39 jdk-17+20_1/failures.linux-x86_64/StressWrapper_suspendthrd003.jtr.release 15303 2021-05-02 12:02 jdk-17+20_2/failures.linux-x86_64/StressWrapper_suspendthrd003.jtr.release --------- ------- 30334 2 files
05-05-2021