RFR: 8214784: Adjust Dictionary and JNIHandle verification

Erik Ă–sterlund erik.osterlund at oracle.com
Wed Dec 5 11:09:21 UTC 2018


Hi Per,

Looks good.

Thanks,
/Erik

On 2018-12-04 13:53, Per Liden wrote:
> Dictionary::verify() and JNIHandles::verify() currently do verification 
> that is unnecessary and incorrect. It currently calls oopDesc::verify(), 
> which not only checks the oop, but also steps out into the heap to 
> verify the actual object and its fields. This is unnecessary because 
> this is already taken care of by CollectedHeap::verify(). It's also 
> incorrect, because when stepping out into the heap you need to ahead to 
> various Barrier/GC restrictions, which the code currently doesn't do. To 
> fix this, the verification done in Dictionary::verify() and 
> JNIHandles::verify() should only check the oop, not the object and its 
> fields.
> 
> In this patch, I'm also cleaning out a ZGC specific check in the JNI 
> verification, which skipped verification of JNI weaks. This check is no 
> longer needed after JDK-8212921.
> 
> Bug: https://bugs.openjdk.java.net/browse/JDK-8214784
> Webrev: http://cr.openjdk.java.net/~pliden/8214784/webrev.0
> 
> /Per


More information about the hotspot-runtime-dev mailing list