Test
gc/gc/stringdedup/TestStringDeduplicationInterned_G1.java with jvmti stress agent crashes with
The hs_err:
#
# A fatal error has been detected by the Java Runtime Environment:
#
# Internal Error (/Users/lmesnik/ws/jdk/agent/open/src/hotspot/share/runtime/mutex.cpp:461), pid=35487, tid=14339
# assert(false) failed: Attempting to acquire lock StringDedup Requests1 Weak alloc lock/oopstorage out of order with lock Service_lock/service -- possible deadlock
#
# JRE version: OpenJDK Runtime Environment (26.0) (fastdebug build 26-internal-adhoc.lmesnik.open)
# Java VM: OpenJDK 64-Bit Server VM (fastdebug 26-internal-adhoc.lmesnik.open, mixed mode, tiered, compressed oops, compressed class ptrs, g1 gc, bsd-aarch64)
# Core dump will be written. Default location: /cores/core.35487
#
# If you would like to submit a bug report, please visit:
# https://bugreport.java.com/bugreport/crash.jsp
#
--------------- S U M M A R Y ------------
Command Line: -Dtidy=/opt/homebrew/bin/tidy -XX:MaxRAMPercentage=3.125 -Dtest.boot.jdk=/Users/lmesnik/tools/jdk-build/macosx-aarch64 -Djava.io.tmpdir=/Users/lmesnik/ws/jdk/agent/open/build/macosx-aarch64-server-fastdebug/test-support/jtreg_test_hotspot_jtreg_tier1_gc/tmp -agentpath:/Users/lmesnik/ws/jdk/agent/open/build/macosx-aarch64-server-fastdebug/images/test/hotspot/jtreg/native/libJvmtiStressAgent.dyLib=debugger=false -XX:+UseG1GC -Xmn50m -Xms100m -Xmx100m -XX:+UnlockDiagnosticVMOptions --add-opens=java.base/java.lang=ALL-UNNAMED -XX:+VerifyAfterGC -Xlog:gc=debug,stringdedup*=debug -XX:+UseStringDeduplication -XX:StringDeduplicationAgeThreshold=3 gc.stringdedup.TestStringDeduplicationTools$InternedTest 3
Host: mbp.local, "Mac16,5" arm64, 16 cores, 64G, Darwin 24.5.0, macOS 15.5 (24F74)
Time: Thu Jul 17 15:17:22 2025 PDT elapsed time: 0.421404 seconds (0d 0h 0m 0s)
--------------- T H R E A D ---------------
Current thread (0x000000011401c210): WorkerThread "GC Thread#0" [id=14339, stack(0x000000016fd24000,0x000000016ff27000) (2060K)]
Stack: [0x000000016fd24000,0x000000016ff27000], sp=0x000000016ff26700, free space=2057k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.dylib+0x13fe0d0] VMError::report(outputStream*, bool)+0x1b00 (mutex.cpp:461)
V [libjvm.dylib+0x1401970] VMError::report_and_die(int, char const*, char const*, char*, Thread*, unsigned char*, void const*, void const*, char const*, int, unsigned long)+0x55c
V [libjvm.dylib+0x5c8a38] print_error_for_unit_test(char const*, char const*, char*)+0x0
V [libjvm.dylib+0xe7ddc0] Mutex::check_rank(Thread*)+0x14c
V [libjvm.dylib+0xe7e214] Mutex::lock_without_safepoint_check(Thread*)+0x54
V [libjvm.dylib+0xef5194] OopStorage::allocate(oop**, unsigned long)+0x50
V [libjvm.dylib+0x1227efc] StringDedup::Requests::refill_buffer()+0xa4
V [libjvm.dylib+0x12280c4] StringDedup::Requests::add(oop)+0x48
V [libjvm.dylib+0x74f0f8] G1FullGCMarker::mark_object(oop)+0x1c0
V [libjvm.dylib+0x74f594] void G1FullGCMarker::mark_and_push<oop>(oop*)+0x164
V [libjvm.dylib+0xe93548] nmethod::oops_do(OopClosure*, bool)+0x88
V [libjvm.dylib+0x8e5838] MarkingNMethodClosure::do_nmethod(nmethod*)+0x48
V [libjvm.dylib+0xc56da0] JvmtiDeferredEventQueue::oops_do(OopClosure*, NMethodClosure*)+0x58
V [libjvm.dylib+0x1041f68] ServiceThread::oops_do_no_frames(OopClosure*, NMethodClosure*)+0x60
V [libjvm.dylib+0x133c8d8] Thread::oops_do(OopClosure*, NMethodClosure*)+0x98
V [libjvm.dylib+0x1351514] Threads::possibly_parallel_threads_do(bool, ThreadClosure*)+0x14c
V [libjvm.dylib+0x1354564] Threads::possibly_parallel_oops_do(bool, OopClosure*, NMethodClosure*)+0x24
V [libjvm.dylib+0x7e62bc] G1RootProcessor::process_java_roots(G1RootClosures*, G1GCPhaseTimes*, unsigned int)+0x90
V [libjvm.dylib+0x7e6588] G1RootProcessor::process_strong_roots(OopClosure*, CLDClosure*, NMethodClosure*)+0x44
V [libjvm.dylib+0x76cd98] G1FullGCMarkTask::work(unsigned int)+0xb8
V [libjvm.dylib+0x147b730] WorkerThread::run()+0x9c
V [libjvm.dylib+0x133bf34] Thread::call_run()+0xf0
V [libjvm.dylib+0xf03748] thread_native_entry(Thread*)+0x138
C [libsystem_pthread.dylib+0x6c0c] _pthread_start+0x88
JavaThread 0x000000011480a410 (nid = 26627) was being processed
gc/gc/stringdedup/TestStringDeduplicationInterned_G1.java with jvmti stress agent crashes with
The hs_err:
#
# A fatal error has been detected by the Java Runtime Environment:
#
# Internal Error (/Users/lmesnik/ws/jdk/agent/open/src/hotspot/share/runtime/mutex.cpp:461), pid=35487, tid=14339
# assert(false) failed: Attempting to acquire lock StringDedup Requests1 Weak alloc lock/oopstorage out of order with lock Service_lock/service -- possible deadlock
#
# JRE version: OpenJDK Runtime Environment (26.0) (fastdebug build 26-internal-adhoc.lmesnik.open)
# Java VM: OpenJDK 64-Bit Server VM (fastdebug 26-internal-adhoc.lmesnik.open, mixed mode, tiered, compressed oops, compressed class ptrs, g1 gc, bsd-aarch64)
# Core dump will be written. Default location: /cores/core.35487
#
# If you would like to submit a bug report, please visit:
# https://bugreport.java.com/bugreport/crash.jsp
#
--------------- S U M M A R Y ------------
Command Line: -Dtidy=/opt/homebrew/bin/tidy -XX:MaxRAMPercentage=3.125 -Dtest.boot.jdk=/Users/lmesnik/tools/jdk-build/macosx-aarch64 -Djava.io.tmpdir=/Users/lmesnik/ws/jdk/agent/open/build/macosx-aarch64-server-fastdebug/test-support/jtreg_test_hotspot_jtreg_tier1_gc/tmp -agentpath:/Users/lmesnik/ws/jdk/agent/open/build/macosx-aarch64-server-fastdebug/images/test/hotspot/jtreg/native/libJvmtiStressAgent.dyLib=debugger=false -XX:+UseG1GC -Xmn50m -Xms100m -Xmx100m -XX:+UnlockDiagnosticVMOptions --add-opens=java.base/java.lang=ALL-UNNAMED -XX:+VerifyAfterGC -Xlog:gc=debug,stringdedup*=debug -XX:+UseStringDeduplication -XX:StringDeduplicationAgeThreshold=3 gc.stringdedup.TestStringDeduplicationTools$InternedTest 3
Host: mbp.local, "Mac16,5" arm64, 16 cores, 64G, Darwin 24.5.0, macOS 15.5 (24F74)
Time: Thu Jul 17 15:17:22 2025 PDT elapsed time: 0.421404 seconds (0d 0h 0m 0s)
--------------- T H R E A D ---------------
Current thread (0x000000011401c210): WorkerThread "GC Thread#0" [id=14339, stack(0x000000016fd24000,0x000000016ff27000) (2060K)]
Stack: [0x000000016fd24000,0x000000016ff27000], sp=0x000000016ff26700, free space=2057k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.dylib+0x13fe0d0] VMError::report(outputStream*, bool)+0x1b00 (mutex.cpp:461)
V [libjvm.dylib+0x1401970] VMError::report_and_die(int, char const*, char const*, char*, Thread*, unsigned char*, void const*, void const*, char const*, int, unsigned long)+0x55c
V [libjvm.dylib+0x5c8a38] print_error_for_unit_test(char const*, char const*, char*)+0x0
V [libjvm.dylib+0xe7ddc0] Mutex::check_rank(Thread*)+0x14c
V [libjvm.dylib+0xe7e214] Mutex::lock_without_safepoint_check(Thread*)+0x54
V [libjvm.dylib+0xef5194] OopStorage::allocate(oop**, unsigned long)+0x50
V [libjvm.dylib+0x1227efc] StringDedup::Requests::refill_buffer()+0xa4
V [libjvm.dylib+0x12280c4] StringDedup::Requests::add(oop)+0x48
V [libjvm.dylib+0x74f0f8] G1FullGCMarker::mark_object(oop)+0x1c0
V [libjvm.dylib+0x74f594] void G1FullGCMarker::mark_and_push<oop>(oop*)+0x164
V [libjvm.dylib+0xe93548] nmethod::oops_do(OopClosure*, bool)+0x88
V [libjvm.dylib+0x8e5838] MarkingNMethodClosure::do_nmethod(nmethod*)+0x48
V [libjvm.dylib+0xc56da0] JvmtiDeferredEventQueue::oops_do(OopClosure*, NMethodClosure*)+0x58
V [libjvm.dylib+0x1041f68] ServiceThread::oops_do_no_frames(OopClosure*, NMethodClosure*)+0x60
V [libjvm.dylib+0x133c8d8] Thread::oops_do(OopClosure*, NMethodClosure*)+0x98
V [libjvm.dylib+0x1351514] Threads::possibly_parallel_threads_do(bool, ThreadClosure*)+0x14c
V [libjvm.dylib+0x1354564] Threads::possibly_parallel_oops_do(bool, OopClosure*, NMethodClosure*)+0x24
V [libjvm.dylib+0x7e62bc] G1RootProcessor::process_java_roots(G1RootClosures*, G1GCPhaseTimes*, unsigned int)+0x90
V [libjvm.dylib+0x7e6588] G1RootProcessor::process_strong_roots(OopClosure*, CLDClosure*, NMethodClosure*)+0x44
V [libjvm.dylib+0x76cd98] G1FullGCMarkTask::work(unsigned int)+0xb8
V [libjvm.dylib+0x147b730] WorkerThread::run()+0x9c
V [libjvm.dylib+0x133bf34] Thread::call_run()+0xf0
V [libjvm.dylib+0xf03748] thread_native_entry(Thread*)+0x138
C [libsystem_pthread.dylib+0x6c0c] _pthread_start+0x88
JavaThread 0x000000011480a410 (nid = 26627) was being processed
- relates to
-
JDK-8364973 Add JVMTI stress testing mode
-
- New
-