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

HotCardCache shouldn't be part of ConcurrentG1Refine

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 9
    • 9
    • hotspot
    • gc
    • b120
    • generic
    • generic

      The ConcurrentG1Refine object has the G1HotCardCache as a member. But the refine object doesn't use the cache in any direct fashion. It just provides an accessor, and a static "enabled" predicate that just forwards to a similar function for provided by G1HotCardCache.

      G1CollectedHeap and G1RemSet call functions on the cache, obtaining it from the refine object.

      Obtaining the cache appears to be the only use of the refinement object by the remset directly. Because the remset obtains the cache from the refine object, we have circular references between refinement and remset.

      It would be better if the hotcard cache were moved from the refinement object to the remset object, or perhaps split out as another object owned by the overall heap object, since access to it is needed there too.

            kbarrett Kim Barrett
            kbarrett Kim Barrett
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: