JDK-8355674 : C2 compilation fails in Matcher::collect_null_checks due to unexpected node
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 25
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2025-04-28
  • Updated: 2025-04-28
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 25
25Unresolved
Related Reports
Causes :  
Description
-Xmx1G -XX:+IgnoreUnrecognizedVMOptions -XX:CompileCommand=quiet -XX:CompileCommand=compileonly,*Test*::* -Xcomp Test_3530.java

# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/opt/mach5/mesos/work_dir/slaves/d2398cde-9325-49c3-b030-8961a4f0a253-S121368/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/fe4dcc7e-2ebc-41c7-98dd-9369ef4ea5cb/runs/8881806f-e08e-44ae-b1cd-11deafad45a0/workspace/open/src/hotspot/share/opto/node.hpp:903), pid=1376231, tid=1376261
#  assert(is_Bool()) failed: invalid node class: Phi
#
# JRE version: Java(TM) SE Runtime Environment (25.0+20) (fastdebug build 25-ea+20-LTS-2387)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (fastdebug 25-ea+20-LTS-2387, compiled mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# V  [libjvm.so+0x15a1783]  Matcher::collect_null_checks(Node*, Node*)+0x3d3

Current CompileTask:
C2:320   10   !b  4       Test_3530::vMeth (327 bytes)

Stack: [0x00007fcd84b3e000,0x00007fcd84c3e000],  sp=0x00007fcd84c399e0,  free space=1006k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [libjvm.so+0x15a1783]  Matcher::collect_null_checks(Node*, Node*)+0x3d3  (node.hpp:903)
V  [libjvm.so+0x15af597]  Matcher::xform(Node*, int)+0x1307  (matcher.cpp:1171)
V  [libjvm.so+0x15b557f]  Matcher::match()+0x10ff  (matcher.cpp:369)
V  [libjvm.so+0xb0739e]  Compile::Code_Gen()+0x1fe  (compile.cpp:2999)
V  [libjvm.so+0xb0ce6b]  Compile::Compile(ciEnv*, ciMethod*, int, Options, DirectiveSet*)+0x200b  (compile.cpp:893)
V  [libjvm.so+0x93b2d7]  C2Compiler::compile_method(ciEnv*, ciMethod*, int, bool, DirectiveSet*)+0x467  (c2compiler.cpp:141)
V  [libjvm.so+0xb1a818]  CompileBroker::invoke_compiler_on_method(CompileTask*)+0xb58  (compileBroker.cpp:2307)
V  [libjvm.so+0xb1b9e8]  CompileBroker::compiler_thread_loop()+0x578  (compileBroker.cpp:1951)
V  [libjvm.so+0x106857b]  JavaThread::thread_main_inner()+0x13b  (javaThread.cpp:773)
V  [libjvm.so+0x1a963a6]  Thread::call_run()+0xb6  (thread.cpp:231)
V  [libjvm.so+0x17275b8]  thread_native_entry(Thread*)+0x128  (os_linux.cpp:875)
Comments
ILW = Assert during C2 compilation due to unexpected node (regression), once at tier8 with JavaFuzzer generated test, no workaround but disable compilation of affected method = HLM = P3
28-04-2025

Regression from JDK-8351280.
28-04-2025