ADDITIONAL SYSTEM INFORMATION :
$ <JAVA_HOME>/bin/java -version
openjdk version "25-internal" 2025-09-16
OpenJDK Runtime Environment (fastdebug build 25-internal-adhoc.user.jdk-mainline)
OpenJDK 64-Bit Server VM (fastdebug build 25-internal-adhoc.user.jdk-mainline, mixed mode)
A DESCRIPTION OF THE PROBLEM :
When running the following code, the JDK crashes with the error message: assert(false) failed: should not be here. The code we provide is a minimized Java test case that reproduces the issue.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
javac Test.java && java Test
ACTUAL -
1912 StrEquals === 1911 2275 1899 1902 714 [[ 2036 ]] !orig=[2034] !jvms: String::equals @ bci:44 (line 1921) Ce::cem @ bci:40 (line 20)
#
# A fatal error has been detected by the Java Runtime Environment:
#
# Internal Error (<JDK-REPO>/hotspot/jdk-24/src/hotspot/share/opto/escape.cpp:4083), pid=2202139, tid=2202163
# assert(false) failed: should not be here
#
# JRE version: OpenJDK Runtime Environment (25.0) (fastdebug build 25-internal-adhoc.qiusy.jdk-24)
# Java VM: OpenJDK 64-Bit Server VM (fastdebug 25-internal-adhoc.qiusy.jdk-24, mixed mode, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# V [libjvm.so+0xd2382b] ConnectionGraph::move_inst_mem(Node*, GrowableArray<PhiNode*>&)+0x8eb
#
# Core dump will be written. Default location: Core dumps may be processed with "/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E" (or dumping to <FOLDER>/Test0789_05_15_11_23_30/reduce/core.2202139)
#
# An error report file with more information is saved as:
# <FOLDER>/Test0789_05_15_11_23_30/reduce/hs_err_pid2202139.log
#
# Compiler replay data is saved as:
# <FOLDER>/Test0789_05_15_11_23_30/reduce/replay_pid2202139.log
#
# If you would like to submit a bug report, please visit:
# https://bugreport.java.com/bugreport/crash.jsp
#
Current CompileTask:
C2:469 509 ! 4 Ce::cem (56 bytes)
Stack: [0x0000787592a00000,0x0000787592b00000], sp=0x0000787592afa7f0, free space=1001k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.so+0xd2382b] ConnectionGraph::move_inst_mem(Node*, GrowableArray<PhiNode*>&)+0x8eb (escape.cpp:4083)
V [libjvm.so+0xd27126] ConnectionGraph::split_unique_types(GrowableArray<Node*>&, GrowableArray<ArrayCopyNode*>&, GrowableArray<MergeMemNode*>&, Unique_Node_List&)+0x3716 (escape.cpp:4935)
V [libjvm.so+0xd2e842] ConnectionGraph::compute_escape()+0x2312 (escape.cpp:396)
V [libjvm.so+0xd2efa3] ConnectionGraph::do_analysis(Compile*, PhaseIterGVN*)+0xe3 (escape.cpp:118)
V [libjvm.so+0xb29f2d] Compile::Optimize()+0x13dd (compile.cpp:2411)
V [libjvm.so+0xb2e203] Compile::Compile(ciEnv*, ciMethod*, int, Options, DirectiveSet*)+0x1ca3 (compile.cpp:863)
V [libjvm.so+0x9743aa] C2Compiler::compile_method(ciEnv*, ciMethod*, int, bool, DirectiveSet*)+0x1ba (c2compiler.cpp:141)
V [libjvm.so+0xb3b7b7] CompileBroker::invoke_compiler_on_method(CompileTask*)+0xad7 (compileBroker.cpp:2298)
V [libjvm.so+0xb3c5a8] CompileBroker::compiler_thread_loop()+0x5c8 (compileBroker.cpp:1942)
V [libjvm.so+0x107232e] JavaThread::thread_main_inner()+0xee (javaThread.cpp:772)
V [libjvm.so+0x1bba82e] Thread::call_run()+0xbe (thread.cpp:224)
V [libjvm.so+0x16c034b] thread_native_entry(Thread*)+0x12b (os_linux.cpp:869)
bash: line 1: 2202139 Aborted (core dumped) <JDK-REPO>/hotspot/jdk-24/build/linux-x86_64-server-fastdebug/jdk/bin/java -cp . Test
---------- BEGIN SOURCE ----------
class Test extends c159.HelperBase {
public static void main(String[] strArr) {
for (int var16 = 0; var16 < 100000; var16++) {
Ce.VALUE2.cem("123456abc", "123456abc");
}
}
}
enum Ce {
VALUE2;
int cem(String id, String nameKey) {
try {
java.io.ByteArrayOutputStream stream = new java.io.ByteArrayOutputStream();
java.math.BigInteger num = java.math.BigInteger.valueOf(123);
int length = num.toByteArray().length;
stream.write(num.toByteArray());
} catch (Exception e) {
}
if ("UTC".equals(id) && id.equals(nameKey))
;
return 0;
}
}
class c159 {
static class HelperBase {
}
}
---------- END SOURCE ----------
$ <JAVA_HOME>/bin/java -version
openjdk version "25-internal" 2025-09-16
OpenJDK Runtime Environment (fastdebug build 25-internal-adhoc.user.jdk-mainline)
OpenJDK 64-Bit Server VM (fastdebug build 25-internal-adhoc.user.jdk-mainline, mixed mode)
A DESCRIPTION OF THE PROBLEM :
When running the following code, the JDK crashes with the error message: assert(false) failed: should not be here. The code we provide is a minimized Java test case that reproduces the issue.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
javac Test.java && java Test
ACTUAL -
1912 StrEquals === 1911 2275 1899 1902 714 [[ 2036 ]] !orig=[2034] !jvms: String::equals @ bci:44 (line 1921) Ce::cem @ bci:40 (line 20)
#
# A fatal error has been detected by the Java Runtime Environment:
#
# Internal Error (<JDK-REPO>/hotspot/jdk-24/src/hotspot/share/opto/escape.cpp:4083), pid=2202139, tid=2202163
# assert(false) failed: should not be here
#
# JRE version: OpenJDK Runtime Environment (25.0) (fastdebug build 25-internal-adhoc.qiusy.jdk-24)
# Java VM: OpenJDK 64-Bit Server VM (fastdebug 25-internal-adhoc.qiusy.jdk-24, mixed mode, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# V [libjvm.so+0xd2382b] ConnectionGraph::move_inst_mem(Node*, GrowableArray<PhiNode*>&)+0x8eb
#
# Core dump will be written. Default location: Core dumps may be processed with "/usr/share/apport/apport -p%p -s%s -c%c -d%d -P%P -u%u -g%g -- %E" (or dumping to <FOLDER>/Test0789_05_15_11_23_30/reduce/core.2202139)
#
# An error report file with more information is saved as:
# <FOLDER>/Test0789_05_15_11_23_30/reduce/hs_err_pid2202139.log
#
# Compiler replay data is saved as:
# <FOLDER>/Test0789_05_15_11_23_30/reduce/replay_pid2202139.log
#
# If you would like to submit a bug report, please visit:
# https://bugreport.java.com/bugreport/crash.jsp
#
Current CompileTask:
C2:469 509 ! 4 Ce::cem (56 bytes)
Stack: [0x0000787592a00000,0x0000787592b00000], sp=0x0000787592afa7f0, free space=1001k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.so+0xd2382b] ConnectionGraph::move_inst_mem(Node*, GrowableArray<PhiNode*>&)+0x8eb (escape.cpp:4083)
V [libjvm.so+0xd27126] ConnectionGraph::split_unique_types(GrowableArray<Node*>&, GrowableArray<ArrayCopyNode*>&, GrowableArray<MergeMemNode*>&, Unique_Node_List&)+0x3716 (escape.cpp:4935)
V [libjvm.so+0xd2e842] ConnectionGraph::compute_escape()+0x2312 (escape.cpp:396)
V [libjvm.so+0xd2efa3] ConnectionGraph::do_analysis(Compile*, PhaseIterGVN*)+0xe3 (escape.cpp:118)
V [libjvm.so+0xb29f2d] Compile::Optimize()+0x13dd (compile.cpp:2411)
V [libjvm.so+0xb2e203] Compile::Compile(ciEnv*, ciMethod*, int, Options, DirectiveSet*)+0x1ca3 (compile.cpp:863)
V [libjvm.so+0x9743aa] C2Compiler::compile_method(ciEnv*, ciMethod*, int, bool, DirectiveSet*)+0x1ba (c2compiler.cpp:141)
V [libjvm.so+0xb3b7b7] CompileBroker::invoke_compiler_on_method(CompileTask*)+0xad7 (compileBroker.cpp:2298)
V [libjvm.so+0xb3c5a8] CompileBroker::compiler_thread_loop()+0x5c8 (compileBroker.cpp:1942)
V [libjvm.so+0x107232e] JavaThread::thread_main_inner()+0xee (javaThread.cpp:772)
V [libjvm.so+0x1bba82e] Thread::call_run()+0xbe (thread.cpp:224)
V [libjvm.so+0x16c034b] thread_native_entry(Thread*)+0x12b (os_linux.cpp:869)
bash: line 1: 2202139 Aborted (core dumped) <JDK-REPO>/hotspot/jdk-24/build/linux-x86_64-server-fastdebug/jdk/bin/java -cp . Test
---------- BEGIN SOURCE ----------
class Test extends c159.HelperBase {
public static void main(String[] strArr) {
for (int var16 = 0; var16 < 100000; var16++) {
Ce.VALUE2.cem("123456abc", "123456abc");
}
}
}
enum Ce {
VALUE2;
int cem(String id, String nameKey) {
try {
java.io.ByteArrayOutputStream stream = new java.io.ByteArrayOutputStream();
java.math.BigInteger num = java.math.BigInteger.valueOf(123);
int length = num.toByteArray().length;
stream.write(num.toByteArray());
} catch (Exception e) {
}
if ("UTC".equals(id) && id.equals(nameKey))
;
return 0;
}
}
class c159 {
static class HelperBase {
}
}
---------- END SOURCE ----------
- relates to
-
JDK-8267532 C2: Profile and prune untaken exception handlers
-
- Resolved
-
-
JDK-8276455 C2: iterative EA
-
- Resolved
-
-
JDK-8350971 C2: assert(idx == alias_idx) failed: Following Phi nodes should be on the same memory slice
-
- Open
-