Problems with JDK 10
Doug Simon
doug.simon at oracle.com
Thu Mar 22 11:10:35 UTC 2018
Hi Stefan,
I'm not aware of any problems with Truffle on JDK 10. This looks like a javac bug. Maybe turn on more flags to see what annotation processing is happening such as -XprintProcessorInfo and -XprintRounds. Compare the output of these flags between 9 and 10.
-Doug
> On 22 Mar 2018, at 08:29, Stefan Marr <java at stefan-marr.de> wrote:
>
> Hi:
>
> Are there any know problems with Truffle and JDK 10?
> Since Homebrew updated its java cask to JDK 10, I got my builds failing on Travis.
> My setup uses the `--release 8` flag, so, I was hoping to avoid any issues.
>
> The javac output, when compiling the whole project is unfortunately less than helpful.
> (see https://travis-ci.org/smarr/SOMns/jobs/356726221#L2353,
> I can only see “package does not exist”, or "cannot find symbol" errors.)
>
> It looks to me as if the annotation processor is failing to run.
>
> Locally, I have been trying to find out whether any specific single file is not building correctly.
> So, I went, compiled everything with Java 9, and then tried compiling some subset with Java 10.
>
> For individual files, nothing seems to be wrong.
> However, when I clean out the compilation for all my builtin functions (som.primitives),
> I get the following lovely error:
>
> ```
> [javac] /Users/smarr/Projects/SOM/SOMns/src/som/primitives/ActivitySpawn.java:167: error: expression not allowed as annotation value
> [javac] @Primitive(primitive = "threading:threadSpawn:with:",
> [javac] ^
> ```
>
> The same compiles fine with JDK 8 and 9.
>
> Even worse, just cleaning out ActivitySpawn compiles fine too:
>
> ```
> $ rm ./src_gen/som/primitives/ActivitySpawnFactory.java ./build/classes/som/primitives/ActivitySpawn*
> $ ant -Dskip.graal=true compile-som
> Buildfile: /Users/smarr/Projects/SOM/SOMns/build.xml
> [echo]
> [echo] ant.java.version: 9
> [echo] java.version: 10
> [echo] is.atLeastJava9: true
> [echo]
>
> compile-som:
> [javac] Compiling 1 source file to /Users/smarr/Projects/SOM/SOMns/build/classes
> [javac] warning: No processor claimed any of these annotations: com.oracle.truffle.api.nodes.Node.Child,com.oracle.truffle.api.dsl.Cached,com.oracle.truffle.api.CompilerDirectives.CompilationFinal,bd.primitives.Primitive.Container,com.oracle.truffle.api.CompilerDirectives.TruffleBoundary,com.oracle.truffle.api.dsl.GenerateNodeFactory,com.oracle.truffle.api.dsl.Specialization,com.oracle.truffle.api.dsl.NodeChild,com.oracle.truffle.api.dsl.ImportStatic
> [javac] warning: No processor claimed any of these annotations: com.oracle.truffle.api.dsl.GeneratedBy,com.oracle.truffle.api.nodes.Node.Child,com.oracle.truffle.api.CompilerDirectives.CompilationFinal
> [javac] 2 warnings
>
> BUILD SUCCESSFUL
> Total time: 1 second
> ```
>
> Did anyone see anything like this before?
>
> Might this be a javac bug?
>
> Thanks
> Stefan
>
> --
> Stefan Marr
> School of Computing, University of Kent
> http://stefan-marr.de/research/
>
>
More information about the graal-dev
mailing list