RFR (S) 8175887: C1 value numbering handling of Unsafe.get*Volatile is incorrect
Paul Sandoz
paul.sandoz at oracle.com
Tue Feb 28 11:04:05 UTC 2017
> On 27 Feb 2017, at 21:25, Aleksey Shipilev <shade at redhat.com> wrote:
>
> On 02/27/2017 03:12 PM, Aleksey Shipilev wrote:
>> On 02/27/2017 10:53 AM, Aleksey Shipilev wrote:
>>> C1 does not have intrinsics for Opaque, and therefore it should delegate Opaque
>>> ops to volatile via fallbacks in Unsafe.java. But now I read the C1
>>> Unsafe.getObject handling, and my hair stand on end, because I think C1 {L,G}VN
>>> does not treat volatile Unsafe ops any specially, while it probably should:
>>> https://bugs.openjdk.java.net/browse/JDK-8175887
>>>
>>> Makes sense?
>>
>> This is the actual reproducible bug, changing the thread subject.
>>
>> Fix against jdk9/hs:
>> http://cr.openjdk.java.net/~shade/8175887/webrev.01/
>
> Updated after off-list review (renamed tests, used internal Unsafe):
> http://cr.openjdk.java.net/~shade/8175887/webrev.02/
>
This looks good, with my limited knowledge of C1 (but expanded with some help from Aleksey on explaining GVN), but need someone from the compiler team to formally review.
Paul.
> 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.
>
> -Aleksey
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 841 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20170228/b67ecd63/signature.asc>
More information about the hotspot-compiler-dev
mailing list