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

JEP 490: ZGC: Remove the Non-Generational Mode

XMLWordPrintable

    • Icon: JEP JEP
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • hotspot
    • None
    • Axel Boldt-Christmas
    • Feature
    • Open
    • gc
    • JDK
    • hotspot dash gc dash dev at openjdk dot org
    • XS
    • XS
    • 490

      Summary

      Remove the non-generational mode of the Z Garbage Collector (ZGC).

      Goal

      • Reduce the maintenance cost of supporting two different modes.

      Motivation

      Maintaining non-generational ZGC slows the development of new features. As stated in JEP 439: Generational ZGC:

      Generational ZGC should be a better solution for most use cases than non-generational ZGC. We should eventually be able to replace the latter with the former in order to reduce long-term maintenance costs.

      Description

      Remove the non-generational mode by obsoleting the ZGenerational option and removing the non-generational ZGC code and its tests. The option will expire in a future release, at which point it will not be recognized by the HotSpot JVM, which will refuse to start.

      After these changes, the relevant command-line options will work as follows:

      • -XX:+UseZGC

        • Generational ZGC is used.
      • -XX:+UseZGC -XX:+ZGenerational

        • Generational ZGC is used.
        • An obsolete-option warning is printed.
      • -XX:+UseZGC -XX:-ZGenerational

        • Generational ZGC is used.
        • An obsolete-option warning is printed.

      Workloads that switch to Generational ZGC may experience differences in log output and in the data available from the serviceability and management APIs.

      Risks and Assumptions

      This JEP shares its Risk and Assumptions with JEP 439: Generational ZGC and JEP 474: ZGC: Generational Mode by Default.

      Generational ZGC will perform differently than non-generational ZGC. The main risk this presents is that some workloads are non-generational by nature, and thus could see a slight performance degradation. We believe that this is a sufficiently small set of workloads that it does not justify the cost of maintaining two separate modes of ZGC over the long term.

      Specific risks include:

      • Users may be required to adjust configurations that are tuned for non-generational ZGC.

      • The obsolete-option warning messages might cause issues.

      • Workloads that are tightly coupled to JVM internals, GC logs, and the data available via management interfaces may require extra attention.

            aboldtch Axel Boldt-Christmas
            aboldtch Axel Boldt-Christmas
            Axel Boldt-Christmas Axel Boldt-Christmas
            Stefan Karlsson, Vladimir Kozlov
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: