JDK-8222748 : [Graal] org.graalvm.compiler.core.test.inlining.PolymorphicInliningTest fails with AssertionError
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 13
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2019-04-18
  • Updated: 2019-05-14
  • Resolved: 2019-05-14
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 13
13Resolved
Related Reports
Duplicate :  
Relates :  
Description
org.graalvm.compiler.core.test.inlining.PolymorphicInliningTest fails with
java.lang.AssertionError
	at org.graalvm.compiler.core.test.inlining.PolymorphicInliningTest.testPolymorphicInlining(PolymorphicInliningTest.java:99)
	at org.graalvm.compiler.core.test.inlining.PolymorphicInliningTest.testInSubprocess(PolymorphicInliningTest.java:69)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:567)
	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
	at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
	at org.junit.runners.Suite.runChild(Suite.java:128)
	at org.junit.runners.Suite.runChild(Suite.java:27)
	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
	at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
	at org.junit.runner.JUnitCore.run(JUnitCore.java:115)
	at com.oracle.mxtool.junit.MxJUnitWrapper.runRequest(MxJUnitWrapper.java:280)
	at com.oracle.mxtool.junit.MxJUnitWrapper.main(MxJUnitWrapper.java:196)

when running with -Xcomp flag.

Comments
This test has loops so I'm assuming it is sensitive to profiling information. Therefore it shouldn't be run with -Xcomp.
23-04-2019

[~dlong] JDK-8192853 was filed against "Graal JIT mode + -Xcomp", this bug is reproduced just in "-server -Xcomp" configuration. So, this is why I filed separate bug.
18-04-2019

[~epavlova] In JDK-8192853, Doug said "I propose that Graal unit tests are not to be run with -Xcomp". So should we make this a duplicate?
18-04-2019

Another failed test is org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest 1) testBranchProbability2(org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest) java.lang.ClassCastException: class org.graalvm.compiler.nodes.DeoptimizeNode cannot be cast to class org.graalvm.compiler.nodes.debug.ControlFlowAnchorNode (org.graalvm.compiler.nodes.DeoptimizeNode and org.graalvm.compiler.nodes.debug.ControlFlowAnchorNode are in module jdk.internal.vm.compiler of loader 'platform') at org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest.returnValue(ProbabilityDirectiveTest.java:89) at org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest.checkLowTierGraph(ProbabilityDirectiveTest.java:77) at org.graalvm.compiler.core.test.GraalCompilerTest$4.run(GraalCompilerTest.java:325) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.Phase.run(Phase.java:49) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:197) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:139) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.PhaseSuite.run(PhaseSuite.java:212) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:197) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:139) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.core.GraalCompiler.emitFrontEnd(GraalCompiler.java:230) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.core.GraalCompiler.compile(GraalCompiler.java:144) at org.graalvm.compiler.core.test.GraalCompilerTest.compile(GraalCompilerTest.java:1102) at org.graalvm.compiler.core.test.GraalCompilerTest.getCode(GraalCompilerTest.java:995) at org.graalvm.compiler.core.test.GraalCompilerTest.getCode(GraalCompilerTest.java:936) at org.graalvm.compiler.core.test.GraalCompilerTest.executeActual(GraalCompilerTest.java:762) at org.graalvm.compiler.core.test.GraalCompilerTest.executeActualCheckDeopt(GraalCompilerTest.java:894) at org.graalvm.compiler.core.test.GraalCompilerTest.testAgainstExpected(GraalCompilerTest.java:884) at org.graalvm.compiler.core.test.GraalCompilerTest.testAgainstExpected(GraalCompilerTest.java:880) at org.graalvm.compiler.core.test.GraalCompilerTest.test(GraalCompilerTest.java:849) at org.graalvm.compiler.core.test.GraalCompilerTest.test(GraalCompilerTest.java:818) at org.graalvm.compiler.core.test.GraalCompilerTest.test(GraalCompilerTest.java:811) at org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest.testBranchProbability2(ProbabilityDirectiveTest.java:67) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:567) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.junit.runners.Suite.runChild(Suite.java:128) at org.junit.runners.Suite.runChild(Suite.java:27) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.junit.runner.JUnitCore.run(JUnitCore.java:137) at org.junit.runner.JUnitCore.run(JUnitCore.java:115) at com.oracle.mxtool.junit.MxJUnitWrapper.runRequest(MxJUnitWrapper.java:280) at com.oracle.mxtool.junit.MxJUnitWrapper.main(MxJUnitWrapper.java:196) 2) testBranchProbability(org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest) java.lang.ClassCastException: class org.graalvm.compiler.nodes.DeoptimizeNode cannot be cast to class org.graalvm.compiler.nodes.debug.ControlFlowAnchorNode (org.graalvm.compiler.nodes.DeoptimizeNode and org.graalvm.compiler.nodes.debug.ControlFlowAnchorNode are in module jdk.internal.vm.compiler of loader 'platform') at org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest.returnValue(ProbabilityDirectiveTest.java:89) at org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest.checkLowTierGraph(ProbabilityDirectiveTest.java:77) at org.graalvm.compiler.core.test.GraalCompilerTest$4.run(GraalCompilerTest.java:325) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.Phase.run(Phase.java:49) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:197) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:139) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.PhaseSuite.run(PhaseSuite.java:212) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:197) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:139) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.core.GraalCompiler.emitFrontEnd(GraalCompiler.java:230) at jdk.internal.vm.compiler@13-internal/org.graalvm.compiler.core.GraalCompiler.compile(GraalCompiler.java:144) at org.graalvm.compiler.core.test.GraalCompilerTest.compile(GraalCompilerTest.java:1102) at org.graalvm.compiler.core.test.GraalCompilerTest.getCode(GraalCompilerTest.java:995) at org.graalvm.compiler.core.test.GraalCompilerTest.getCode(GraalCompilerTest.java:936) at org.graalvm.compiler.core.test.GraalCompilerTest.executeActual(GraalCompilerTest.java:762) at org.graalvm.compiler.core.test.GraalCompilerTest.executeActualCheckDeopt(GraalCompilerTest.java:894) at org.graalvm.compiler.core.test.GraalCompilerTest.testAgainstExpected(GraalCompilerTest.java:884) at org.graalvm.compiler.core.test.GraalCompilerTest.testAgainstExpected(GraalCompilerTest.java:880) at org.graalvm.compiler.core.test.GraalCompilerTest.test(GraalCompilerTest.java:849) at org.graalvm.compiler.core.test.GraalCompilerTest.test(GraalCompilerTest.java:818) at org.graalvm.compiler.core.test.GraalCompilerTest.test(GraalCompilerTest.java:811) at org.graalvm.compiler.api.directives.test.ProbabilityDirectiveTest.testBranchProbability(ProbabilityDirectiveTest.java:52) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:567) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.junit.runners.Suite.runChild(Suite.java:128) at org.junit.runners.Suite.runChild(Suite.java:27) at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290) at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71) at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288) at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58) at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268) at org.junit.runners.ParentRunner.run(ParentRunner.java:363) at org.junit.runner.JUnitCore.run(JUnitCore.java:137) at org.junit.runner.JUnitCore.run(JUnitCore.java:115) at com.oracle.mxtool.junit.MxJUnitWrapper.runRequest(MxJUnitWrapper.java:280) at com.oracle.mxtool.junit.MxJUnitWrapper.main(MxJUnitWrapper.java:196)
18-04-2019

If this test is not suitable for running with -Xcomp flag then let me know whether it should be fixed similar to https://github.com/oracle/graal/blob/ae813716ed6525dc4db5c51e7ef3cc904f73c18d/compiler/src/org.graalvm.compiler.core.test/src/org/graalvm/compiler/core/test/ProfilingInfoTest.java#L188-L192 (see JDK-8192853)
18-04-2019

To reproduce run compiler/graalunit/CoreTest.java or create open/test/hotspot/jtreg/compiler/graalunit/Bug.java with following content: /* * @test * @summary * @requires vm.opt.final.EnableJVMCI == true * @requires !vm.graal.enabled * @modules jdk.internal.vm.compiler * * @library /test/lib /compiler/graalunit / * * @build compiler.graalunit.common.GraalUnitTestLauncher * * @run main compiler.graalunit.common.GraalUnitTestLauncher -prefix org.graalvm.compiler.core.test.inlining.PolymorphicInliningTest */ and then run > make run-test TEST="compiler/graalunit/Bug.java" TEST_VM_OPTS="-XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -XX:+TieredCompilation -XX:-UseJVMCICompiler -Xcomp"
18-04-2019