RFR (S) 8175887: C1 value numbering handling of Unsafe.get*Volatile is incorrect

Vladimir Ivanov vladimir.x.ivanov at oracle.com
Tue Feb 28 15:28:08 UTC 2017


Thanks for the fix, Aleksey.

> Updated after off-list review (renamed tests, used internal Unsafe):
>   http://cr.openjdk.java.net/~shade/8175887/webrev.02/

I'm fine with the fix in do_UnsafeGetObject.

Changes in do_UnsafeGetRaw don't make much sense to me. Following the 
reasoning in the comment ("better be safe than sorry") you have to
unconditionally kill memory for UnsafeGetObject as well :-)

If there's a need in ordering raw loads, I'd prefer to see a dedicated 
flag (like UnsafeObjectOp::_is_volatile) introduced instead.
Right now, UnsafeGetRaw usage is very limited (only for restoring frame 
state in OSR entry), so I don't see any reason in doing that.

So, please, leave it as is.

Best regards,
Vladimir Ivanov

> Everything else still stands:
>
>> Testing: Linux x86_64/release hotspot/test/compiler, includes new tests
>>
>> I need a sponsor. I think this bugfix is too important to miss 9, and it even
>> deserves backporting to 8u.


More information about the hotspot-compiler-dev mailing list