8012715: GraphKit accesses PtrQueue::_index as int but is size_t [Was: Re: RFR (S): G1: Fix bug in graphKit.cpp accessing PtrQueue::_index]

Christian Thalinger christian.thalinger at oracle.com
Fri Apr 19 11:36:58 PDT 2013


Here is a bug number:

8012715: GraphKit accesses PtrQueue::_index as int but is size_t

I don't really like T_X.  Let me talk to Vladimir about this.

-- Chris

On Apr 19, 2013, at 5:02 AM, "Doerr, Martin" <martin.doerr at sap.com> wrote:

> Hi all,
>  
> we found a bug in the G1 barriers generated by the C2 compiler.
>  
> In graphKit INT operations were generated to access PtrQueue::_index which
> has type size_t. This is 64 bit on 64-bit machines. No problems occur on
> little endian machines as long as the index fits into 32 bit, but on
> big endian machines the upper part is read, which is zero. This leads
> to unnecessary branches to the slow path into the runtime.
>  
> The fix introduces X operations where INT was used:
> http://cr.openjdk.java.net/~goetz/webrevs/g1-size_t_bug/
>  
> This also removes a cast node.
>  
> We have also added a type T_X in globalDefinitions.hpp. Is there
> already a mechanism to express this?
>  
> Please supply a bug id and review this change.
>  
> Best regards,
> Martin
>  

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20130419/dba97630/attachment.html 


More information about the hotspot-compiler-dev mailing list