RFR: 6522873 - Java not print "Unrecognized option" when it is invalid option.
Max Ockner
max.ockner at oracle.com
Fri Dec 5 20:30:39 UTC 2014
Jesper,
I have reviewed your change (I am not an official reviewer yet, but I
have recent experience with this code).
True, there was a recent discussion about this issue, but only obsolete
arguments were targeted. I have inspected your change, and I am
convinced that there isn't really a better way to correct this
additional issue.
Max O
The only other solution I can think of is to move all flags into the
flagTable, since the code which checks tabled flags already seems to
work. But I'm no longer
On 12/5/2014 8:39 AM, Jesper Wilhelmsson wrote:
> Hi,
>
> Please review this patch to make argument parsing stop accepting
> random characters at the end of command line flags. This topic was
> discussed in hotspot-dev at openjdk.java.net and I strongly believe that
> this bug should be reopened and fixed.
>
> Short summary of the problem:
> Today some (not all) flags are accepted even though they have random
> characters appended to them. Some examples are -Xconcgc, -Xcomp,
> -Xboundthreads, -XX:+AlwaysTenure etc which will also be accepted when
> written for instance -Xconcgcnoway, -Xcomposer, -Xboundthreadstodogs
> or -XX:+AlwaysTenureAtBlueMoon
>
> There is a potential problem here since we will also accept things
> like -XX:+ExtendedDTraceProbes-XX:+UseG1GC without saying a word (and
> of course without running with G1).
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-6522873
> Webrev: http://cr.openjdk.java.net/~jwilhelm/6522873/webrev.00/
>
>
> The full list of flags affected by this change is:
>
> -Xnoclassgc
> -Xconcgc
> -Xnoconcgc
> -Xbatch
> -green
> -native
> -Xsqnopause
> -Xrs
> -Xusealtsigs
> -Xoptimize
> -Xprof
> -Xconcurrentio
> -Xinternalversion
> -Xprintflags
> -Xint
> -Xmixed
> -Xcomp
> -Xshare:dump
> -Xshare:on
> -Xshare:auto
> -Xshare:off
> -Xdebug
> -Xnoagent
> -Xboundthreads
> vfprintf
> exit
> abort
> -XX:+AggressiveHeap
> -XX:+NeverTenure
> -XX:+AlwaysTenure
> -XX:+CMSPermGenSweepingEnabled
> -XX:-CMSPermGenSweepingEnabled
> -XX:+UseGCTimeLimit
> -XX:-UseGCTimeLimit
> -XX:+ResizeTLE
> -XX:-ResizeTLE
> -XX:+PrintTLE
> -XX:-PrintTLE
> -XX:+UseTLE
> -XX:-UseTLE
> -XX:+DisplayVMOutputToStderr
> -XX:+DisplayVMOutputToStdout
> -XX:+ExtendedDTraceProbes
> -XX:+FullGCALot
> -XX:+ManagementServer
> -XX:+PrintVMOptions
> -XX:-PrintVMOptions
> -XX:+IgnoreUnrecognizedVMOptions
> -XX:-IgnoreUnrecognizedVMOptions
> -XX:+PrintFlagsInitial
> -XX:+PrintFlagsWithComments
>
>
> Thanks,
> /Jesper
More information about the hotspot-runtime-dev
mailing list