java.lang.NoClassDefFoundError: com/oracle/truffle/api/TruffleRuntimeAccess while running with self built Graal JDK
Doug Simon
doug.simon at oracle.com
Mon Nov 23 23:13:32 UTC 2015
What happens when you run this in your graal-compiler directory:
mx -v sl ../truffle/truffle/com.oracle.truffle.sl.test/src/tests/HelloWorld.sl
-Doug
> On 23 Nov 2015, at 23:56, Renze Torensma <renzetorensma at gmail.com> wrote:
>
> Hi,
>
> After following the instructions on the wiki page for building a Graal VM (https://wiki.openjdk.java.net/display/Graal/Instructions <https://wiki.openjdk.java.net/display/Graal/Instructions>) and setting up Eclipse (https://wiki.openjdk.java.net/display/Graal/Eclipse <https://wiki.openjdk.java.net/display/Graal/Eclipse>) I managed to get SL running on a normal JDK (1.8.0_60) but when I select the Graal JDK I built (same version, 1.8.0_60) as alternative JRE I get a java.lang.InternalError:
>
> Exception in thread "main" java.lang.InternalError
> at com.oracle.truffle.api.Truffle$1.run(Truffle.java:86)
> at com.oracle.truffle.api.Truffle$1.run(Truffle.java:1)
> at java.security.AccessController.doPrivileged(Native Method)
> at com.oracle.truffle.api.Truffle.initRuntime(Truffle.java:47)
> at com.oracle.truffle.api.Truffle.<clinit>(Truffle.java:37)
> at com.oracle.truffle.api.impl.Accessor.<clinit>(Accessor.java:270)
> at com.oracle.truffle.api.TruffleLanguage.<clinit>(TruffleLanguage.java:441)
> Caused by: java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:497)
> at com.oracle.truffle.api.Truffle$1.run(Truffle.java:83)
> ... 6 more
> Caused by: java.lang.NoClassDefFoundError: com/oracle/truffle/api/TruffleRuntimeAccess (suppress with -Djvmci.service.suppressNoClassDefFoundError=true)
> at jdk.vm.ci.service.Services$1.computeValue(Services.java:59)
> at jdk.vm.ci.service.Services$1.computeValue(Services.java:50)
> at java.lang.ClassValue.getFromHashMap(ClassValue.java:227)
> at java.lang.ClassValue.getFromBackup(ClassValue.java:209)
> at java.lang.ClassValue.get(ClassValue.java:115)
> at jdk.vm.ci.service.Services.loadSingle(Services.java:105)
> ... 11 more
>
> The workspace reports 0 problems, even no warnings about deprecated code which seems a little odd to me. I’m not sure what I’m doing wrong, and I don’t really know how to use the provided Truffle and Graal builds on http://lafo.ssw.uni-linz.ac.at/builds <http://lafo.ssw.uni-linz.ac.at/builds> to check if that would fix the problem. I tested on Eclipse Luna and Eclipse Mars and with JDK 1.8.0_60 and 1.8.0_66 but the error happens in all cases.
>
> Thanks,
> Renze
More information about the graal-dev
mailing list