JDK-8213751 : ClassLoaderDataGraph::cld_do() should sometimes require CLDG_lock
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 12
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2018-11-12
  • Updated: 2019-05-28
  • Resolved: 2018-11-16
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 12
12 b21Fixed
Related Reports
Relates :  
Relates :  
Description
The runtime and JFR code that calls ClassLoaderDataGraph::cld_do() should use the ClassLoaderDataGraphIterator which asserts that the CLDG_lock is taken.   The GC code that uses the function should not.

For runtime calls, it should also skip unloaded classes.
Comments
Thanks to [~eosterlund] for noticing this.
12-11-2018