RFR(XXS) 8217522: Missing barriers in some java_lang_String assertion code after JDK-8213229

Zhengyu Gu zgu at redhat.com
Wed Jan 23 00:28:56 UTC 2019

On 1/22/19 5:52 PM, Claes Redestad wrote:
> On 2019-01-22 22:00, Zhengyu Gu wrote:
>>> Ah, dang. I suggested oopDesc::equals_raw to Claes, hoping that would 
>>> be enough. Yes, stronger
>>> oopDesc::equals is preferred. It is mildly irritating those can be 
>>> different copies of the object,
>>> though, but it is safe because we are only reading from them.
>> I noticed that, his final patch does not have oopDesc::equals_raw ...
> There was a version of that patch out for review - based on suggestions
> from David Holmes - which we ended up backing away from. The pushed
> patch uses oopDesc::equals_raw in a few assertions:
> http://hg.openjdk.java.net/jdk/jdk/rev/bc2bb4eee477

Ah, I did not realize equals_raw was from this changeset :-) I thought 
they are pre-existing code. Sorry for the confusing replies.

> Changing these to oopDesc::equals sounds OK to me.

Thanks for the review, Aleksey and Claes.


> /Claes

More information about the hotspot-gc-dev mailing list