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

G1: Use live data set to adaptively set max young gen size or G1MaxYounGenPercent

XMLWordPrintable

    • gc
    • generic
    • generic

      The performance team have asked for this particuilar change.

      The idea came from looking at logs from a specific workload that has changed since last September and the live data set of the application has significantly increased.

      The workload is run with a 2.5G heap and the live data set is around 1900M.

      The basic idea would be to recalculate the value of G1MaxNewSizePercent ergonomically at the end of a full GC and a completed marking cycle based upon how much live data is in the heap (Live Data Set). So currently the default value of G1MaxNewSizePercent is 60. With the heap settings and LDS of the workload in question it would make sense to reduce G1MaxNewSizePercent to 25% of the heap and lower the upper bound on the young gen size.

      In G1, instead of live data set, we would look at how many free heap regions we have available (perhaps even subtracting the ReservePercenrt).

      Such a policy should prevent an evacuation failure and a disastrously long full GC at the expense of increasing the GC overhead.

      An additional experiment would be to set the upper bound of the young generation to half of the free space - say 12% in the example above.

            Unassigned Unassigned
            johnc John Cuthbertson
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: