Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8193933

Export ClassLoaderData claim state to support interleaved object traversal

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P2
    • Resolution: Fixed
    • Affects Version/s: 10
    • Fix Version/s: 10
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Introduced In Version:
      10
    • Resolved In Build:
      b40

      Backports

        Description

        We have a closed component that uses ClassLoaderDataGraph::clear_claimed_marks() to get a set of fresh claiming bits for object traversal.

        This interferes with the concurrent marking GCs, that are using this information to determine if a CLD has been marked through our not.

        The effect is that there's a possibility that some class loaders won't get marked and classes might be prematurely unloaded, which would lead to crashes.

        We probably would want to redesign the CLDG claiming, to allow multiple claim sets. But in the meantime, a work around could be that the closed component introduce a mechanism that will save and restore the original claim bits.

        In order to add this save/restore mechanism, we would need to publicly export the ClassLoaderData "claim" set of member functions.

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  mgronlun Markus Grönlund
                  Reporter:
                  mgronlun Markus Grönlund
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: