JDK-8317506 : assert(!VerifyHashTableKeys || _hash_lock == 0) failed
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 8
  • Priority: P4
  • Status: New
  • Resolution: Unresolved
  • OS: linux_ubuntu
  • CPU: x86_64
  • Submitted: 2023-09-25
  • Updated: 2023-10-04
Description
ADDITIONAL SYSTEM INFORMATION :
# JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug--b00)
# Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug mixed mode linux-amd64 compressed oops)

A DESCRIPTION OF THE PROBLEM :
I ran a modified regression testcase on JDK8u392 and found that the JVM crashed without any options.

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/data//jdk8u/hotspot/src/share/vm/opto/node.hpp:407), pid=11048, tid=0x00007f8491646700
#  assert(!VerifyHashTableKeys || _hash_lock == 0) failed: remove node from hash table before modifying it
#
# JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug--b00)
# Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug mixed mode linux-amd64 compressed oops)
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
#

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
java compiler.macronodes.TestCompleteVolatileStore

ACTUAL -
# To suppress the following error report, specify this argument
# after -XX: or in .hotspotrc:  SuppressErrorAt=/node.hpp:407
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/data//jdk8u/hotspot/src/share/vm/opto/node.hpp:407), pid=11048, tid=0x00007f8491646700
#  assert(!VerifyHashTableKeys || _hash_lock == 0) failed: remove node from hash table before modifying it
#
# JRE version: OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug--b00)
# Java VM: OpenJDK 64-Bit Server VM (25.392-b00-fastdebug mixed mode linux-amd64 compressed oops)
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /home//repository//toreport/TestCompleteVolatileStore_09_24_23_50_43/hs_err_pid11048.log
#
# Compiler replay data is saved as:
# /home//repository//toreport/TestCompleteVolatileStore_09_24_23_50_43/replay_pid11048.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.java.com/bugreport/crash.jsp
#

---------- BEGIN SOURCE ----------
The source code file and hs_err file are available at the URL:
https://drive.google.com/file/d/18ivReNw2KkLXlsSBrlg9hNUzqYAj046b/view?usp=sharing
---------- END SOURCE ----------

FREQUENCY : always



Comments
JDK version used by submitter is OpenJDK Runtime Environment (8.0_392) (build 1.8.0_392-internal-fastdebug--b00) Available Oracle JDK version is 1.8.0_381-b32 Testcase crashes with Oracle JDK 1.8.0_381-fastdebug-b32 and when excluded method no crashes observed # A fatal error has been detected by the Java Runtime Environment: # # Internal Error (/scratch/jenkins/workspace/8-2-build-linux-x64-sans-NAS/jdk8u381-bpr/317/hotspot/src/share/vm/opto/node.hpp:407), pid=11950, tid=0x00007fba249f1700 # assert(!VerifyHashTableKeys || _hash_lock == 0) failed: remove node from hash table before modifying it # # JRE version: Java(TM) SE Runtime Environment (8.0_381) (build 1.8.0_381-fastdebug-b32) # Java VM: Java HotSpot(TM) 64-Bit Server VM (25.381-b32-fastdebug mixed mode linux-amd64 compressed oops) # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again # # If you would like to submit a bug report, please visit: # http://bugreport.java.com/bugreport/crash.jsp # --------------- T H R E A D --------------- Current thread (0x00007fba2015f800): JavaThread "C2 CompilerThread0" daemon [_thread_in_native, id=11956, stack(0x00007fba248f2000,0x00007fba249f2000)] Stack: [0x00007fba248f2000,0x00007fba249f2000], sp=0x00007fba249ec730, free space=1001k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) V [libjvm.so+0x11af4ed] VMError::report_and_die()+0x2fd V [libjvm.so+0x7a3f51] report_vm_error(char const*, int, char const*, char const*)+0x61 V [libjvm.so+0x33453f] Node::set_req(unsigned int, Node*)+0x25f V [libjvm.so+0xdcc551] InitializeNode::complete_stores(Node*, Node*, Node*, long, Node*, PhaseGVN*)+0x3b1 V [libjvm.so+0xd43789] PhaseMacroExpand::initialize_object(AllocateNode*, Node*, Node*, Node*, Node*, Node*, Node*)+0x469 V [libjvm.so+0xd48157] PhaseMacroExpand::expand_allocate_common(AllocateNode*, Node*, TypeFunc const*, unsigned char*)+0xaf7 V [libjvm.so+0xd4a4e8] PhaseMacroExpand::expand_macro_nodes()+0x638 V [libjvm.so+0x707c70] Compile::Optimize()+0xcb0 V [libjvm.so+0x708c28] Compile::Compile(ciEnv*, C2Compiler*, ciMethod*, int, bool, bool, bool, bool)+0xe28 V [libjvm.so+0x594de0] C2Compiler::compile_method(ciEnv*, ciMethod*, int)+0x110 V [libjvm.so+0x717b92] CompileBroker::invoke_compiler_on_method(CompileTask*)+0x942 V [libjvm.so+0x719178] CompileBroker::compiler_thread_loop()+0x858 V [libjvm.so+0x111f848] JavaThread::thread_main_inner()+0x198 V [libjvm.so+0x111fb50] JavaThread::run()+0x2c0 V [libjvm.so+0xeb55f2] java_start(Thread*)+0x102 C [libpthread.so.0+0x7ea5] start_thread+0xc5 Current CompileTask: C2: 381 51 ! 4 sun.reflect.GeneratedMethodAccessor1::invoke (62 bytes) When excluded method no crash reported #java -showversion -XX:CompileCommand=exclude,sun/reflect/GeneratedMethodAccessor1,invoke TestCompleteVolatileStore CompilerOracle: exclude sun/reflect/GeneratedMethodAccessor1.invoke java version "1.8.0_381-fastdebug" Java(TM) SE Runtime Environment (build 1.8.0_381-fastdebug-b32) Java HotSpot(TM) 64-Bit Server VM (build 25.381-b32-fastdebug, mixed mode) ### Excluding compile: sun.reflect.GeneratedMethodAccessor1::invoke
29-09-2023