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

Use an array to store the collection set regions instead of linking through regions

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
    • Subcomponent:
      gc
    • Resolved In Build:
      b129

      Description

      Currently the collection set is materialized using pointer members in the HeapRegion class, using a "next" pointer.

      This is problematic in various ways:
      - messes up the HeapRegion class with an additional member that is only used for a small part of the regions anyway.
      - it is not thread safe, and actually the sampling thread iterates over this linked list without any proper memory barriers, potentially causing crashes or at least problems with the prediction (using wrong values)
      - the change to free the collection set (JDK-8034842) in parallel needs to be extra cautious to not read old values.

      Fix this as suggested in the CR title.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                tschatzl Thomas Schatzl
                Reporter:
                tschatzl Thomas Schatzl
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: