RFR 8066171: Out of order with Metaspace allocation lock
coleen.phillimore at oracle.com
Fri Dec 5 15:58:21 UTC 2014
On 12/4/14, 10:53 PM, David Holmes wrote:
> Hi Coleen,
> Do you care that you can now block at safepoints when acquiring the lock?
No, I don't think it matters that this can block.
> On 4/12/2014 2:59 AM, Coleen Phillimore wrote:
>> Summary: Lock resolved_references instead.
>> When I took out the constant pool mutex, I thought I could use the
>> metaspace to synchronize this code sequence, but the metaspace_lock is
>> out of order with the DirtyCardQ_CBL_mon lock that can sometimes be
>> taken with obj_at_put() in an object array. Since there is always a
>> resolved_reference objArrayOop attached to this class, we can lock this
>> for this cpCache entry. John and the JSR292 guys tell me that this code
>> sequence needs to be locked against multiple setters.
>> Tested with jdk/test/java/lang/invoke tests, nsk.quick.testlist.
>> open webrev at http://cr.openjdk.java.net/~coleenp/8066171/
>> bug link https://bugs.openjdk.java.net/browse/JDK-8066171
More information about the hotspot-dev