RFR 8066171: Out of order with Metaspace allocation lock
coleen.phillimore at oracle.com
Wed Dec 3 17:29:16 UTC 2014
I forgot to mention I tested by locking the DirtyCardQ_CBL_mon lock
unconditionally in ConstantPoolCacheEntry::set_method_handle_common.
On 12/3/14, 11: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