JEP 490: ZGC: Remove the Non-Generational Mode

OwnerAxel Boldt-Christmas
TypeFeature
ScopeJDK
StatusIntegrated
Release24
Componenthotspot / gc
Discussionhotspot dash gc dash dev at openjdk dot org
EffortXS
DurationXS
Relates toJEP 439: Generational ZGC
JEP 474: ZGC: Generational Mode by Default
Reviewed byStefan Karlsson, Vladimir Kozlov
Endorsed byVladimir Kozlov
Created2024/07/08 08:41
Updated2024/11/01 13:13
Issue8335850

Summary

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

Goal

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:

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: