Open code review for 8061999 Enhance VM option parsing to allow options to be specified
Ron Durbin
ron.durbin at oracle.com
Tue Jun 23 17:43:42 UTC 2015
David,
The '-XX:Flags' option was considered during the research phase
of this project and was rejected because of its limitations. The
'-XX:Flags' option only works for boolean flag options and it
uses a different syntax for the options than the command line.
For example, '-XX:+UseSerialGC' would be specified as '+UseSerialGC'
in the '-XX:Flags' option file.
Here's an example:
$ cat foo
+UseSerialGC
java -XX:+PrintVMOptions -XX:Flags=foo -version
VM option '+UseSerialGC'
VM option '+PrintVMOptions'
VM option 'Flags=foo'
java version "1.9.0-ea"
Java(TM) SE Runtime Environment (build 1.9.0-ea-b69)
Java HotSpot(TM) 64-Bit Server VM (build 1.9.0-ea-b69, mixed mode)
Ron
> -----Original Message-----
> From: David Holmes
> Sent: Monday, June 22, 2015 11:12 PM
> To: Ron Durbin; hotspot-runtime-dev at openjdk.java.net
> Subject: Re: Open code review for 8061999 Enhance VM option parsing to allow options to be specified
>
> Hi Ron,
>
> On 22/06/2015 10:52 PM, Ron Durbin wrote:
> > Webrev URL:
> > http://cr.openjdk.java.net/~rdurbin/8061999_OCR0_JDK9_webrev
> >
> >
> > RFE request:
> > https://bugs.openjdk.java.net/browse/JDK-8061999
> >
> > This RFE allows a file to be specified that holds VM Options that
> > would otherwise be specified on the command line or in an environment variable.
> > Only one options file may be specified on the command line and no options file
> > may be specified in either of the following environment variables
> > "JAVA_TOOL_OPTIONS" or "_JAVA_OPTIONS".
>
> How is this different to the existing: -XX:Flags=flags-file ???
>
> David
> -----
>
> > The options file feature supports all VM options currently supported on
> > the command line, except the options file option. The option to specify an
> > options file is "-XX:VMOptionsFile=<Filename>".
> > The options file feature supports an options file up to 1024 bytes in size
> > and up to 64 options.
> >
> > This feature has been tested on:
> > OS:
> > Solaris, MAC, Windows, Linux
> > Tests:
> > Manual unit tests
> > JPRT with -testset hotspot (including the SQE proposed test coverage for this feature.)
> >
> >
More information about the hotspot-runtime-dev
mailing list