Skip to content

[GR-76514] Graal compilation of jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean) exits VM with GraalError "could not find Vector API type for VectorAPICompare" #13751

@SunParis

Description

@SunParis

Description

Compiling the provided Vector API test with Graal and -Dgraal.CompilationFailureAction=ExitVM -Xcomp fails during compilation of jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean). Expected behavior: the program compiles and runs normally. Actual behavior: Graal reports [[[Graal compilation failure]]] and exits the VM with jdk.graal.compiler.debug.GraalError: failed guarantee: could not find Vector API type for 823|VectorAPICompare (a!# jdk.incubator.vector.Int256Vector$Int256Mask).

System & Java Version

Control Group OpenJDK Version: 
    openjdk version "25.0.3" 2026-04-21
    OpenJDK Runtime Environment (build 25.0.3)
    OpenJDK 64-Bit Server VM (build 25.0.3, mixed mode, sharing)
GraalVM JDK Version: 
    openjdk version "25.0.3-internal" 2026-04-21
    OpenJDK Runtime Environment GraalVM CE 25.1.0-dev.internal-adhoc.syc.labs-openjdk.1 (build 25.0.3-internal-adhoc.syc.labs-openjdk)
    OpenJDK 64-Bit Server VM GraalVM CE 25.1.0-dev.internal-adhoc.syc.labs-openjdk.1 (build 25.0.3-internal-adhoc.syc.labs-openjdk, mixed mode, sharing)
GraalVM Commit: d91a2b7e4647d6639d689d878f7255c9cd83ed32
LabsOpenJDK Commit:  a04ba0087a48ce0091be170d845fe24769590943 (HEAD, tag: jvmci-25.1-b18)
MX Commit: cf215dfd24f26a31cea19416599c041ce6d664ff (HEAD -> master, tag: 7.82.3, origin/master, origin/HEAD)
Build GCC: gcc-10 (Arch Linux 10.5.0-2) 10.5.0
OS: Linux 7.0.11-arch1-1

Reproduction

  1. Place Test.java and run.sh in the same directory.
  2. If reproducing manually, use the commands shown in the run.sh section below.
  3. Use the existing bug_output contents below as the captured failing output.

Command script used for the captured run:

/home/syc/Desktop/code/jvm/jdk25u-graal/build/bin/java -ea -esa -XX:+UseJVMCICompiler \
    -Dgraal.CompilationFailureAction=ExitVM -Xcomp --add-modules jdk.incubator.vector \
    -XX:+UnlockDiagnosticVMOptions -XX:CompileThreshold=64 -XX:-UseInlineCaches \
    -Dtest.jdk=/home/syc/Desktop/code/jvm/jdk25u-graal/build -Djdk.test.lib.random.seed=1 \
    Test.java > run.log 2>&1
/usr/lib/jvm/java-25-openjdk/bin/java -ea -esa --add-modules jdk.incubator.vector Test.java > run2.log 2>&1
diff run.log run2.log > bug_output 2>&1

Suspected Component

Vector API / Graal compiler

Exception Output

Compilation failed for jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean) @ -1. Primary error: jdk.graal.compiler.debug.GraalError: failed guarantee: could not find Vector API type for 823|VectorAPICompare (a!# jdk.incubator.vector.Int256Vector$Int256Mask).

Output kind: crash

2,38c2,33
< 0, 2, -4, -2, [Use -Djdk.graal.LogFile=<path> to redirect Graal log output to a file.]
< [[[Graal compilation failure]]]
< Thread[#9715,JVMCI-native CompilerThread0,5,main]: Compilation of jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean) @ -1 failed:
< jdk.graal.compiler.debug.GraalError: failed guarantee: could not find Vector API type for 823|VectorAPICompare (a!# jdk.incubator.vector.Int256Vector$Int256Mask)
< 	at [823|VectorAPICompare { stamp=a!# jdk.incubator.vector.Int256Vector$Int256Mask, bci=42, callerMethod=HotSpotMethod<IntVector.compareTemplate(Class, VectorOperators$Comparison, Vector)>, targetMethod=HotSpotMethod<VectorSupport.compare(int, Class, Class, Class, int, VectorSupport$Vector, VectorSupport$Vector, VectorSupport$VectorMask, VectorSupport$VectorCompareOp)>, invokeKind=Static, returnStamp=a!# jdk.incubator.vector.Int256Vector$Int256Mask, constantValue=null, inputStamp=<i32,i32,i32,i32,i32,i32,i32,i32>, logicStamp=<i32 [-1 - 0],i32 [-1 - 0],i32 [-1 - 0],i32 [-1 - 0],i32 [-1 - 0],i32 [-1 - 0],i32 [-1 - 0],i32 [-1 - 0]>, condition=EQ, canonicalizedCondition=jdk.graal.compiler.core.common.calc.Condition$CanonicalizedCondition@6d947a7e,  }]
< 	at LibGraalClassLoader//jdk.graal.compiler.vector.replacements.vectorapi.VectorAPIExpansionPhase.replaceComponentFrameStateUsages(VectorAPIExpansionPhase.java:1087)
< 	at LibGraalClassLoader//jdk.graal.compiler.vector.replacements.vectorapi.VectorAPIExpansionPhase.replaceComponentNodes(VectorAPIExpansionPhase.java:1017)
< 	at LibGraalClassLoader//jdk.graal.compiler.vector.replacements.vectorapi.VectorAPIExpansionPhase.expandComponents(VectorAPIExpansionPhase.java:627)
< 	at LibGraalClassLoader//jdk.graal.compiler.vector.replacements.vectorapi.VectorAPIExpansionPhase.run(VectorAPIExpansionPhase.java:305)
< 	at LibGraalClassLoader//jdk.graal.compiler.vector.replacements.vectorapi.VectorAPIExpansionPhase.run(VectorAPIExpansionPhase.java:154)
< 	at LibGraalClassLoader//jdk.graal.compiler.phases.BasePhase.apply(BasePhase.java:511)
< 	at LibGraalClassLoader//jdk.graal.compiler.phases.BasePhase.apply(BasePhase.java:359)
< 	at LibGraalClassLoader//jdk.graal.compiler.core.phases.BaseTier.run(BaseTier.java:65)
< 	at LibGraalClassLoader//jdk.graal.compiler.phases.BasePhase.apply(BasePhase.java:511)
< 	at LibGraalClassLoader//jdk.graal.compiler.phases.BasePhase.apply(BasePhase.java:359)
< 	at LibGraalClassLoader//jdk.graal.compiler.core.GraalCompiler.emitFrontEnd(GraalCompiler.java:283)
< 	at LibGraalClassLoader//jdk.graal.compiler.core.GraalCompiler.compile(GraalCompiler.java:152)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.HotSpotGraalCompiler.compileHelper(HotSpotGraalCompiler.java:302)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.HotSpotGraalCompiler.compile(HotSpotGraalCompiler.java:332)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.CompilationTask$HotSpotCompilationWrapper.performCompilation(CompilationTask.java:307)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.CompilationTask$HotSpotCompilationWrapper.performCompilation(CompilationTask.java:152)
< 	at LibGraalClassLoader//jdk.graal.compiler.core.CompilationWrapper.run(CompilationWrapper.java:236)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.CompilationTask.runCompilation(CompilationTask.java:664)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.CompilationTask.runCompilation(CompilationTask.java:626)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.HotSpotGraalCompiler.compileMethod(HotSpotGraalCompiler.java:203)
< 	at LibGraalClassLoader//jdk.graal.compiler.hotspot.HotSpotGraalCompiler.compileMethod(HotSpotGraalCompiler.java:137)
< 	at LibGraalClassLoader//jdk.vm.ci.hotspot.HotSpotJVMCIRuntime.compileMethod(HotSpotJVMCIRuntime.java:939)
< Options: {CompilationFailureAction=ExitVM}
< If in an environment where setting system properties is possible, the following
< properties are available to change compilation failure reporting:
< - To disable compilation failure notifications, set CompilationFailureAction to Silent (e.g., -Djdk.graal.CompilationFailureAction=Silent).
< - To print a message for a compilation failure without retrying the compilation, set CompilationFailureAction to Print (e.g., -Djdk.graal.CompilationFailureAction=Print).
< Retrying compilation of jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean) @ -1
< Dumping IGV graphs in /home/syc/Desktop/code/jdk-bugs/GraalVM25/graal_dumps/2026.06.10.13.10.22.987/graal_diagnostics_1850719@0/jdk.incubator.vector.Int256Vector.iotaShuffle(int,_int,_boolean)_@_-1
< Serialized 20285:jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean)@-1 to /home/syc/Desktop/code/jdk-bugs/GraalVM25/graal_dumps/2026.06.10.13.10.22.987/graal_diagnostics_1850719@0/jdk.incubator.vector.Int256Vector.iotaShuffle(int,_int,_boolean)_@_-1/replaycomp/20285.replay
< Exiting VM after retry compilation of jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean) @ -1
< Graal diagnostic output saved in '/home/syc/Desktop/code/jdk-bugs/GraalVM25/graal_dumps/2026.06.10.13.10.22.987/graal_diagnostics_1850719@0.zip'
---
> 0, 2, -4, -2, char lv_char_1781064656268_928830676174333:: 98
> char lv_char_1781064656238_928830369473902:: 52
> char lv_char_1781064656238_928830369351601:: 52
> int[] lv_int_arr_1781064656284_928830834736772:: at 0 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 1 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 2 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 4 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 7 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 11 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 17 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 26 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 40 151
> int[] lv_int_arr_1781064656284_928830834736772:: at 61 151
> String lv_String_1781064656238_928830371043653:: `false`
> String lv_String_1781064656235_928830344095400:: `asdfasf123123`
> String lv_String_1781064656238_928830367889462:: ``
> String lv_String_1781064656238_928830371770944:: `false`
> float lv_float_1781064656229_928830278227430:: 1.1470769E7
> float lv_float_1781064656284_928830833125903:: 216.34413
> long lv_long_1781064656235_928830341574410:: 44790
> int lv_int_1781064656235_928830342894540:: 669
> float[] lv_float_arr_1781064656237_928830366442750:: at 0 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 1 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 2 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 4 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 7 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 11 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 17 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 26 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 40 268.75485
> float[] lv_float_arr_1781064656237_928830366442750:: at 61 268.75485
> java.lang.AssertionError

GraalVM Crash Artifacts

  • Failed compilation: jdk.incubator.vector.Int256Vector.iotaShuffle(int, int, boolean) @ -1
  • Primary error: jdk.graal.compiler.debug.GraalError: failed guarantee: could not find Vector API type for 823|VectorAPICompare (a!# jdk.incubator.vector.Int256Vector$Int256Mask)

Rerun command used to collect Graal logs:

/home/syc/Desktop/code/jvm/jdk25u-graal/build/bin/java -Djdk.graal.LogFile=/home/syc/Desktop/code/jdk-bugs/GraalVM25/graal_crash_rerun_20260610-211042.graal.log -ea -esa -XX:+UseJVMCICompiler -Dgraal.CompilationFailureAction=ExitVM -Xcomp --add-modules jdk.incubator.vector -XX:+UnlockDiagnosticVMOptions -XX:CompileThreshold=64 -XX:-UseInlineCaches -Dtest.jdk=/home/syc/Desktop/code/jvm/jdk25u-graal/build -Djdk.test.lib.random.seed=1 Test.java

Rerun exit code: 255

Graal Dump Files:

Source Code

Test.java

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions