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

G1: Enqueuing dirty cards during reference enqueuing in phase 3 does not scale

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Not an Issue
    • Affects Version/s: 9
    • Fix Version/s: tbd
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
      gc

      Description

      For G1 there is a problem with enqueuing references in phase 3. That enqueue applies the barrier set's write_ref_field to the discovered links being added to the pending list. If the reference is young, this isn't a problem because the write barrier doesn't need to do anything in that case. But if the reference is old, it's going to record a dirty card, and that's going to be in the shared global DirtyCardQueue, since the call is from a non-Java thread. So a locking DCQ.enqueue per reference, and severe lock contention when parallelized. One possiblity might be a special purpose variant of write_ref_field for use here, with most collectors just forwarding to their normal write_ref_field implementation, but G1 using per-worker DCQs.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              sangheki Sangheon Kim
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: