JDK-8212992 : Change mirror accessor in Klass::verify_on() to use AS_NO_KEEPALIVE
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 12
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2018-10-25
  • Updated: 2021-07-12
  • Resolved: 2018-11-20
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11 JDK 12
11.0.5Fixed 12 b21Fixed
Related Reports
Relates :  
Relates :  
Description
The Klass::verify_on() is sometimes called on unloaded klasses. It then reads a dead mirror, without using AS_NO_KEEPALIVE, which can make GC barriers feel like :C. In order to make barriers happy, AS_NO_KEEPALIVE should be used when loading dead oops.
Comments
Fix Request (11u) Backport is required for concurrent class-unloading GC to work properly. Provides clean base for JDK-8224531 backport. Needs JDK-8210063 to work. Passes tier1 afterwards. Risk is low: accesses the same field with more lax decorator.
24-07-2019

Depends on JDK-8210063 for ZGC to work. Otherwise AS_NO_KEEPALIVE is rejected by ZGC BarrierSet, detectable with compiler/gcbarriers/UnsafeIntrinsicsTest.java test.
24-07-2019