RFR: 8309136: [JVMCI] add -XX:+UseGraalJIT flag

David Holmes dholmes at openjdk.org
Wed May 31 07:31:58 UTC 2023

On Tue, 30 May 2023 22:31:13 GMT, Doug Simon <dnsimon at openjdk.org> wrote:

> Use of the Graal-based JIT in OpenJDK currently requires the following flag: `-XX:+EnableJVMCIProduct`
> This has no direct association with Graal. If the JDK image happens to include a non-Graal JVMCI implementation, it will be automatically selected. This would come as a surprise to users who equate JVMCI with Graal.
> This PR introduces a new flag, `-XX:+UseGraalJIT` to address these shortcomings. The VM fails fast at startup if there is a non-Graal JVMCI implementation or no JVMCI implementation in the JDK image.

A couple of minor items but otherwise the flag handling seems fine (though not what was linked in the CSR request).


src/hotspot/share/jvmci/jvmci_globals.hpp line 51:

> 49:           "Enable JVMCI")                                                   \
> 50:                                                                             \
> 51:   product(bool, UseGraalJIT, false,                                         \

This should be EXPERIMENTAL

src/hotspot/share/jvmci/jvmci_globals.hpp line 52:

> 50:                                                                             \
> 51:   product(bool, UseGraalJIT, false,                                         \
> 52:           "Select the Graal JVMCI compiler. This is a macro for: "          \

s/a macro/an alias/ please


Changes requested by dholmes (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/14231#pullrequestreview-1452387120
PR Review Comment: https://git.openjdk.org/jdk/pull/14231#discussion_r1211206390
PR Review Comment: https://git.openjdk.org/jdk/pull/14231#discussion_r1211206940

More information about the graal-dev mailing list