RFR: 8039244: Don't use UINT32_FORMAT and INT32_FORMAT when printing uints and ints in the GC code

Vladimir Kozlov vladimir.kozlov at oracle.com
Tue Apr 8 16:42:13 UTC 2014


So *_FORMAT are not broken (when used correctly). It is GC group's decision to use %d and %u in GC code. Right?
It is bad that different components of JVM will be inconsistent in this but it is your decision.

Thanks,
Vladimir

On 4/8/14 1:15 AM, Stefan Karlsson wrote:
>
> On 2014-04-04 09:59, Stefan Karlsson wrote:
>> Please, review this patch to the GC code to change usages of UINT32_FORMAT and INT32_FORMAT to %u and %d when uints
>> and ints are used.
>>
>> While doing this change I found, and changed, a couple of places where we used UINT32_FORMAT to print variables that
>> were less than 4 bytes.
>
> This change is not strictly needed, since varargs methods will widen the types of the arguments. Thanks David Holmes for
> pointing this out.
>
>>
>> webrev: http://cr.openjdk.java.net/~stefank/8039244/webrev.00/
>> bug: https://bugs.openjdk.java.net/browse/JDK-8039244
>
> I'm going to push the webrev.02 version now. I haven't heard back from all that commented on this thread, so if someone
> feels that this needs to be discussed more we can start a new discussion or open a new RFE.
>
> thanks,
> StefanK
>
>>
>> thanks,
>> StefanK
>



More information about the hotspot-gc-dev mailing list