RFR (XS): 8014890 : Reference queues may return more entries than expected

Aleksey Shipilev aleksey.shipilev at oracle.com
Mon Jul 1 10:14:17 UTC 2013

On 07/01/2013 02:05 PM, Thomas Schatzl wrote:
> Fyi, while waiting for your approval, I tried to clean up this a little
> taking into account the comments from Peter and Aleksey (sorry if I
> forgot somebody) into account.

Mandy Chung?

> A webrev for this is at
> http://cr.openjdk.java.net/~tschatzl/8014890/webrev.refactor/ 

This looks good.

The same "thou shalt not do multiple volatile reads" applies to
"(r.queue == NULL) || (r.queue == ENQUEUED)" now. Also, continuing on
the micro-optimization spree, you might want to use bitwise |, not
logical ||, saving a branch. Both things are optional though, it does
not hurt much at this point due to the synchronization, and we can
address these if/when we do the overhaul of that entire code.


More information about the core-libs-dev mailing list