JDK-8365570 : C2 fails assert(false) failed: Unexpected node in SuperWord truncation: CastII
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 25
  • Priority: P3
  • Status: Open
  • Resolution: Unresolved
  • OS: linux
  • CPU: x86_64
  • Submitted: 2025-08-14
  • Updated: 2025-08-18
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 26
26Unresolved
Related Reports
Causes :  
Description
The following test failed in the JDK25 CI:

applications/javafuzzer/JF_5000Tests.java

Here's a snippet from the log file:

#section:main
----------messages:(7/527)----------
command: main -Xbootclasspath/a:. -Dtest.generator.number_of_tests=5000 -Dtest.generator.filter=javafuzzer_tests applications.javafuzzer.TestGeneratorRunner
reason: User specified action: run main/othervm/timeout=20000 -Xbootclasspath/a:. -Dtest.generator.number_of_tests=5000 -Dtest.generator.filter=javafuzzer_tests applications.javafuzzer.TestGeneratorRunner 
started: Thu Aug 14 13:49:13 UTC 2025
Mode: othervm [/othervm specified]
Process id: 998069
finished: Thu Aug 14 15:59:52 UTC 2025
elapsed time (seconds): 7839.234
----------configuration:(0/0)----------
----------System.out:(32/3190)----------
For random generator using seed: -2388094602060681063
To re-run test with same seed value please add "-Djdk.test.lib.random.seed=-2388094602060681063" to command line.
Using the following path for FailureHandler: '/opt/mach5/mesos/work_dir/jib-master/install/jdk-25+36-3489/linux-x64-debug.test/failure_handler/jtregFailureHandler.jar'
Using JRuby dist: /opt/mach5/mesos/work_dir/slaves/f7f8bd65-a387-4a2b-b519-702f2fefaf87-S165858/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/c6d73877-3548-47e4-9b67-39ef9e51654c/runs/5d3460e3-5972-4f8d-9652-148312f32270/./jib-data/install/org/jruby/jruby-dist/9.2.12.0/jruby-dist-9.2.12.0-bin.zip/jruby-9.2.12.0
Using JavaFuzzer dist: /opt/mach5/mesos/work_dir/slaves/f7f8bd65-a387-4a2b-b519-702f2fefaf87-S165858/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/c6d73877-3548-47e4-9b67-39ef9e51654c/runs/5d3460e3-5972-4f8d-9652-148312f32270/./jib-data/install/com/oracle/jpg/bigapps/javafuzzer/javafuzzer/4.0/javafuzzer-4.0.zip
Using FuzzGen dist: /opt/mach5/mesos/work_dir/slaves/f7f8bd65-a387-4a2b-b519-702f2fefaf87-S165858/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/c6d73877-3548-47e4-9b67-39ef9e51654c/runs/5d3460e3-5972-4f8d-9652-148312f32270/./jib-data/install/com/oracle/jpg/bigapps/javafuzzer/fuzzgen/1.5/fuzzgen-1.5.zip
Generating 5000 tests
Summary total: GEN: 53:37:56     COMP: 01:28:49     REF: 33:56:30     VER: 01:48:33    
Summary mean : GEN: 00:00:38.615 COMP: 00:00:01.065 REF: 00:00:24.438 VER: 00:00:01.302
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/opt/mach5/mesos/work_dir/slaves/f7f8bd65-a387-4a2b-b519-702f2fefaf87-S221202/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/d792a0bb-4c2d-4958-bb78-5beb66804bc3/runs/63001f48-caf1-4167-ae65-8dbff201e6fa/workspace/open/src/hotspot/share/opto/superword.cpp:2606), pid=1325600, tid=1325655
#  assert(false) failed: Unexpected node in SuperWord truncation: CastII
#
# JRE version: Java(TM) SE Runtime Environment (25.0+36) (fastdebug build 25+36-LTS-3489)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (fastdebug 25+36-LTS-3489, compiled mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# V  [libjvm.so+0x1a7252c]  VLoopTypes::compute_vector_element_type()+0xcac
#
# Core dump will be written. Default location: Core dumps may be processed with "/opt/core.sh %p" (or dumping to /opt/mach5/mesos/work_dir/slaves/f7f8bd65-a387-4a2b-b519-702f2fefaf87-S165858/frameworks/1735e8a2-a1db-478c-8104-60c8b0af87dd-0196/executors/c6d73877-3548-47e4-9b67-39ef9e51654c/runs/5d3460e3-5972-4f8d-9652-148312f32270/testoutput/test-support/jtreg_closed_test_hotspot_jtreg_applications_javafuzzer_JF_5000Tests_java/scratch/0/generated/javafuzzer_tests/core.1325600)
#
# If you would like to submit a bug report, please visit:
#   https://bugreport.java.com/bugreport/crash.jsp
#

====================== 
Total: 5000; Failed: 1; Passed: 2776; Ignored: 2223
====================== 
--------------------------------------------------
TEST: javafuzzer_tests/Test_1077.java
TEST RESULT: Failed. Exit codes mismatch:  expected: 0 but was: 134
----------System.err:(18/1556)----------


Here's the crashing thread's stack trace:

---------------  T H R E A D  ---------------

Current thread (0x00007fb2081ad8c0):  JavaThread "C2 CompilerThread0" daemon [_thread_in_native, id=1325655, stack(0x00007fb1e191f000,0x00007fb1e1a1f000) (1024K)]


Current CompileTask:
C2:306   10    b  4       Test_1077::vMeth (236 bytes)

Stack: [0x00007fb1e191f000,0x00007fb1e1a1f000],  sp=0x00007fb1e1a196a0,  free space=1001k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [libjvm.so+0x1a7252c]  VLoopTypes::compute_vector_element_type()+0xcac  (superword.cpp:2606)
V  [libjvm.so+0x1b9da81]  VLoopAnalyzer::setup_submodules_helper()+0x91  (vectorization.cpp:195)
V  [libjvm.so+0x1b9daf4]  VLoopAnalyzer::setup_submodules()+0x44  (vectorization.cpp:158)
V  [libjvm.so+0x1554c0d]  PhaseIdealLoop::auto_vectorize(IdealLoopTree*, VSharedData&)+0x8fd  (vectorization.hpp:713)
V  [libjvm.so+0x1532ecd]  PhaseIdealLoop::build_and_optimize()+0xfdd  (loopnode.cpp:5049)
V  [libjvm.so+0xb3f8a3]  PhaseIdealLoop::optimize(PhaseIterGVN&, LoopOptsMode)+0x4f3  (loopnode.hpp:1174)
V  [libjvm.so+0xb36c46]  Compile::optimize_loops(PhaseIterGVN&, LoopOptsMode)+0xb6  (compile.cpp:2262)
V  [libjvm.so+0xb399b1]  Compile::Optimize()+0xcc1  (compile.cpp:2511)
V  [libjvm.so+0xb3cb23]  Compile::Compile(ciEnv*, ciMethod*, int, Options, DirectiveSet*)+0x1f33  (compile.cpp:868)
V  [libjvm.so+0x961e97]  C2Compiler::compile_method(ciEnv*, ciMethod*, int, bool, DirectiveSet*)+0x467  (c2compiler.cpp:141)
V  [libjvm.so+0xb4bf68]  CompileBroker::invoke_compiler_on_method(CompileTask*)+0xb58  (compileBroker.cpp:2327)
V  [libjvm.so+0xb4d138]  CompileBroker::compiler_thread_loop()+0x578  (compileBroker.cpp:1971)
V  [libjvm.so+0x10a17fb]  JavaThread::thread_main_inner()+0x13b  (javaThread.cpp:774)
V  [libjvm.so+0x1afbae6]  Thread::call_run()+0xb6  (thread.cpp:243)
V  [libjvm.so+0x1781158]  thread_native_entry(Thread*)+0x128  (os_linux.cpp:868)
Comments
A pull request was submitted for review. Branch: master URL: https://git.openjdk.org/jdk/pull/26827 Date: 2025-08-18 16:34:52 +0000
18-08-2025

Jasmine, could you please have a look? Thanks.
18-08-2025

ILW = Same as JDK-8362979 = P3
18-08-2025