RFR: 8132306: java/lang/ref/ReferenceEnqueue.java fails with "RuntimeException: Error: poll() returned null; expected ref object"

Daniel Fuchs daniel.fuchs at oracle.com
Fri Jul 31 09:10:32 UTC 2015


On 31/07/15 00:56, Kim Barrett wrote:
> On Jul 30, 2015, at 5:33 PM, David Holmes <david.holmes at oracle.com> wrote:
>>
>>> So I think I can either:
>>>
>>> 1. Go ahead with my change + Peter's change.
>>>
>>> 2. Give this back to core-libs while I step carefully away :-)
>>>
>>> I *think* option (1) is at least an improvement.  But I completely
>>> missed Peter's race, despite having specifically looked for problems
>>> there, so take my opinion with an appropriate quantity of salt.
>>
>> I vote for 1 as well. I think we have now given good coverage to the two sources of problems (the two lock-free regions):
>> - reference queue state can be seen while queue state is in transition
>> - queue empty state can be seen while reference state is in transition
>
> New webrev, with both changes:
>
> http://cr.openjdk.java.net/~kbarrett/8132306/webrev.01/
>

+ 1

Thanks for taking care of this one!

PS: you might want to add @bug 8132306 to
     jdk/test/java/lang/ref/ReferenceEnqueue.java

best regards,

-- daniel



More information about the hotspot-gc-dev mailing list