review (XS) for 7002666: eclipse CDT projects crash with compressed oops

Tom Rodriguez tom.rodriguez at oracle.com
Wed Dec 1 10:17:56 PST 2010


Thanks Christian and Vladimir.

tom

On Dec 1, 2010, at 1:32 AM, Christian Thalinger wrote:

> On Nov 30, 2010, at 8:48 PM, Tom Rodriguez wrote:
>> http://cr.openjdk.java.net/~never/7002666/
>> 
>> 7002666: eclipse CDT projects crash with compressed oops
>> Reviewed-by:
>> 
>> When emitting the code to zero a newly allocated object C2 attempts to
>> identify space that's already been initialized or extra space that
>> isn't actually part of an instance.  The logic for this should only be
>> executed for instances and never for arrays but the logic doesn't
>> explicitly test for arrays.  It's normally protected in the array case
>> because the klass is precise and the value of layout_helper will never
>> match zeroes_done since it's always negative for arrays.  In this case
>> the newArray is producing something that's typed as Object so the
>> klass input of the allocation says Object and it mistakenly assumes
>> the rest of the array doesn't need zeroing.  The fix is to only
>> execute this logic for AllocateNodes.  Tested with eclipse and with
>> new test case.
>> 
>> src/share/vm/opto/memnode.cpp
>> test/compiler/7002666/Test7002666.java
> 
> Looks good.  -- Christian



More information about the hotspot-compiler-dev mailing list