JDK-8255914 : [AOT] Using AOT flag should give warning when AOT is not included in build
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 16
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2020-11-04
  • Updated: 2020-11-12
  • Resolved: 2020-11-05
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 16
16 b24Fixed
Related Reports
Relates :  
Description
Currently if AOT is not included in a build AOT flags specified on command line are silently ignored:

$ java -XX:+UnlockExperimentalVMOptions -XX:+UseAOT -version
java version "16-internal" 2021-03-16
Java(TM) SE Runtime Environment (fastdebug build 16-internal+0-2020-11-04-2338514)
Java HotSpot(TM) 64-Bit Server VM (fastdebug build 16-internal+0-2020-11-04-2338514, mixed mode, sharing)

We should give warning that AOT is not supported in such builds.
Comments
Changeset: 1b59595e Author: Vladimir Kozlov <kvn@openjdk.org> Date: 2020-11-05 17:18:19 +0000 URL: https://github.com/openjdk/jdk/commit/1b59595e
05-11-2020

See existing uses of UNSUPPORTED_OPTION in arguments.cpp
05-11-2020