You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This application is actually a tiny isolated part of the "func" application that I referred to in #497. The app there actually compiles now, but this one doesn't, so that's a bit weird?
The lines of code that start the stack trace for sure are using reflection in a way that is very hard to configure ahead of time, but this code path will never be hit in this application, so I thought the --report-unsupported-elements-at-runtime flag would be enough to get something runnable.
$ mx native-image -H:Name=auto -H:ReflectionConfigurationFiles=${HOME}/dev/scratch/graal/reflect.json --report-unsupported-elements-at-runtime -cp /home/dsyer/dev/scratch/graal/target/classes/:/home/dsyer/dev/scratch/graal/target/graal-test-0.0.1-SNAPSHOT-shaded.jar Autowires
classlist: 971.47 ms
(cap): 977.65 ms
setup: 1,817.68 ms
analysis: 8,550.10 ms
error: Error encountered while parsing com.oracle.svm.reflect.proxies.Proxy_18_Proxy_proxyClassCache.get(java.lang.Object)
Parsing context:
parsing java.lang.reflect.Field.get(Field.java:393)
parsing org.springframework.beans.TypeConverterDelegate.attemptToConvertStringToEnum(TypeConverterDelegate.java:328)
parsing org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:254)
parsing org.springframework.beans.TypeConverterDelegate.convertIfNecessary(TypeConverterDelegate.java:117)
parsing org.springframework.beans.TypeConverterSupport.doConvert(TypeConverterSupport.java:70)
parsing org.springframework.beans.TypeConverterSupport.convertIfNecessary(TypeConverterSupport.java:52)
parsing org.springframework.beans.factory.support.ConstructorResolver.resolvePreparedArguments(ConstructorResolver.java:777)
parsing org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:410)
parsing org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1264)
parsing org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1113)
parsing org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getSingletonFactoryBeanForTypeCheck(AbstractAutowireCapableBeanFactory.java:960)
parsing org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getTypeForFactoryBean(AbstractAutowireCapableBeanFactory.java:834)
parsing org.springframework.beans.factory.support.AbstractBeanFactory.getType(AbstractBeanFactory.java:635)
parsing org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveNamedBean(DefaultListableBeanFactory.java:1025)
parsing org.springframework.beans.factory.support.DefaultListableBeanFactory.getBean(DefaultListableBeanFactory.java:339)
parsing org.springframework.beans.factory.support.DefaultListableBeanFactory.getBean(DefaultListableBeanFactory.java:334)
parsing Autowires.run(Autowires.java:30)
parsing Autowires.main(Autowires.java:16)
parsing com.oracle.svm.reflect.proxies.Proxy_1_Autowires_main.invoke(Unknown Source)
parsing java.lang.reflect.Method.invoke(Method.java:498)
parsing com.oracle.svm.core.JavaMainWrapper.run(JavaMainWrapper.java:173)
parsing com.oracle.svm.core.code.CEntryPointCallStubs.com_002eoracle_002esvm_002ecore_002eJavaMainWrapper_002erun_0028int_002corg_002egraalvm_002enativeimage_002ec_002etype_002eCCharPointerPointer_0029(generated:0)
Original error: org.graalvm.compiler.graph.GraalGraphError: com.oracle.svm.core.util.VMError$HostedError: should not reach here
at node: 4|LoadField#proxyClassCache
at org.graalvm.compiler.phases.common.CanonicalizerPhase$Instance.tryCanonicalize(CanonicalizerPhase.java:340)
at org.graalvm.compiler.phases.common.CanonicalizerPhase$Instance.processNode(CanonicalizerPhase.java:262)
at org.graalvm.compiler.phases.common.CanonicalizerPhase$Instance.processWorkSet(CanonicalizerPhase.java:241)
at org.graalvm.compiler.phases.common.CanonicalizerPhase$Instance.run(CanonicalizerPhase.java:211)
at org.graalvm.compiler.phases.common.CanonicalizerPhase.run(CanonicalizerPhase.java:125)
at org.graalvm.compiler.phases.common.CanonicalizerPhase.run(CanonicalizerPhase.java:66)
at org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:197)
at org.graalvm.compiler.phases.BasePhase.apply(BasePhase.java:139)
at com.oracle.graal.pointsto.flow.MethodTypeFlowBuilder.parse(MethodTypeFlowBuilder.java:206)
at com.oracle.graal.pointsto.flow.MethodTypeFlowBuilder.apply(MethodTypeFlowBuilder.java:315)
at com.oracle.graal.pointsto.flow.MethodTypeFlow.doParse(MethodTypeFlow.java:310)
at com.oracle.graal.pointsto.flow.MethodTypeFlow.ensureParsed(MethodTypeFlow.java:300)
at com.oracle.graal.pointsto.flow.MethodTypeFlow.addContext(MethodTypeFlow.java:107)
at com.oracle.graal.pointsto.DefaultAnalysisPolicy$DefaultVirtualInvokeTypeFlow.onObservedUpdate(DefaultAnalysisPolicy.java:186)
at com.oracle.graal.pointsto.flow.TypeFlow.notifyObservers(TypeFlow.java:347)
at com.oracle.graal.pointsto.flow.TypeFlow.update(TypeFlow.java:389)
at com.oracle.graal.pointsto.BigBang$2.run(BigBang.java:500)
at com.oracle.graal.pointsto.util.CompletionExecutor.lambda$execute$0(CompletionExecutor.java:174)
at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1402)
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)
Caused by: com.oracle.svm.core.util.VMError$HostedError: should not reach here
at com.oracle.svm.core.util.VMError.shouldNotReachHere(VMError.java:62)
at com.oracle.svm.hosted.substitute.AnnotatedField.allowConstantFolding(AnnotatedField.java:78)
at com.oracle.svm.hosted.ameta.AnalysisConstantFieldProvider.readConstantField(AnalysisConstantFieldProvider.java:57)
at org.graalvm.compiler.nodes.util.ConstantFoldUtil.tryConstantFold(ConstantFoldUtil.java:47)
at org.graalvm.compiler.nodes.java.LoadFieldNode.asConstant(LoadFieldNode.java:157)
at org.graalvm.compiler.nodes.java.LoadFieldNode.canonical(LoadFieldNode.java:125)
at org.graalvm.compiler.nodes.java.LoadFieldNode.canonical(LoadFieldNode.java:116)
at org.graalvm.compiler.nodes.java.LoadFieldNode.canonical(LoadFieldNode.java:66)
at org.graalvm.compiler.graph.spi.Canonicalizable$Unary.canonical(Canonicalizable.java:99)
at org.graalvm.compiler.phases.common.CanonicalizerPhase$Instance.tryCanonicalize(CanonicalizerPhase.java:335)
... 22 more
Error: Image building with exit status 1
The text was updated successfully, but these errors were encountered:
This application is actually a tiny isolated part of the "func" application that I referred to in #497. The app there actually compiles now, but this one doesn't, so that's a bit weird?
The lines of code that start the stack trace for sure are using reflection in a way that is very hard to configure ahead of time, but this code path will never be hit in this application, so I thought the
--report-unsupported-elements-at-runtime
flag would be enough to get something runnable.It runs fine with regular Java:
Then
The text was updated successfully, but these errors were encountered: