RFR (S) 8019968: Reference CAS induces GC store barrier even on failure

Aleksey Shipilev aleksey.shipilev at oracle.com
Wed Jul 29 08:58:51 UTC 2015


Hi,

I would like to suggest a fix for:
  https://bugs.openjdk.java.net/browse/JDK-8019968

In short, current reference CAS intrinsic blindly emits post_barrier,
ignoring the CAS result. In some cases, notably contended CAS
spin-loops, we fail the CAS a lot, and thus go for a post_barrier
excessively. Instead, we can conditionalize on the result of the store
itself, and put the post_barrier only on success path:
  http://cr.openjdk.java.net/~shade/8019968/webrev.01/

More performance results here:
  http://cr.openjdk.java.net/~shade/8019968/notes.txt

Thanks,
-Aleksey

P.S. Thanks to Vladimir Ivanov, who manhandled me through dealing with
GraphKit/IdealKit interop.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20150729/4680f752/signature.asc>


More information about the hotspot-compiler-dev mailing list