RFR(XS): 8042885: java does not take hexadecimal number as vm option

Yumin Qi yumin.qi at oracle.com
Thu May 15 19:31:50 UTC 2014


Dmitry,

   Thanks for the suggestion, I like to keep the old one since we need 
check both 'x' and 'X', also it is more straight forward.

--Yumin

On 5/15/2014 12:19 PM, Dmitry Samersoff wrote:
> Yumin,
>
> You might consider to simplify the code a bit:
>
>   const char *fmt =
>     ((*(s+1) & ~0x80) == 'x') ? "0x" JULONG_FORMAT_X : JULONG_FORMAT;
>
>   args_read = sscanf(s, fmt, &n);
>
> -Dmitry
>
>
> On 2014-05-13 21:24, Yumin Qi wrote:
>> Hi, please review the small change for
>>
>> bug: https://bugs.openjdk.java.net/browse/JDK-8042885
>> webrev: http://cr.openjdk.java.net/~minqi/8042885/
>>
>> Summary: Java does not take number with hexadecimal format as options,
>> like -XX:SharedBaseAddress=0x1D000000 will cause VM exit with improper
>> argument. For addresses, we more like to use hexadecimal format since it
>> is close to machine address display naturally.
>>
>> Tests: JPRT and manual test:  java -XX:UnlockDiagnosticVMOptions
>> -XX:SharedBaseAddress=0x1D000000 -Xshare:dump
>>
>> Thanks
>> Yumin
>



More information about the hotspot-runtime-dev mailing list