Integrated: 8377180: Shenandoah: make escalation from degen to full more conservative
Kelvin Nilsen
kdnilsen at openjdk.org
Mon Feb 9 21:39:05 UTC 2026
On Wed, 4 Feb 2026 17:11:33 GMT, Kelvin Nilsen <kdnilsen at openjdk.org> wrote:
> This PR merges into Traditional Shenandoah an optimization that was applied to Generational Shenandoah in September 2025 and has proven itself effective in that context. See https://github.com/openjdk/jdk/pull/27456
>
> The change is to not immediately escalate Degenerated GC to Full GC following "bad progress" by Degen GC. The most common reason for bad degenerated progress is that most of the potential garbage was created following the start of the concurrent GC cycle which degenerated. This "floating" garbage cannot be reclaimed by the degenerated cycle because of the SATB protocol.
>
> Pursuing at least one additional concurrent cycle, even if that subsequent concurrent GC degenerates, is usually a much better approach than forcing immediate escalation to Full GC. While escalation to full GC will resolve the out-of-memory condition, it imposes unnecessarily long stop-the-world pauses:
>
> Existing behavior not to scale:
> <- [ Conc GC ] -> <- [ Degen ] -> <- [ Full GC ]
> [ experiences ] [ with ]
> [ allocation ] [ bad ]
> [ failure ] [ progress ]
> [ STW pause is 100 ms degen + 3s full GC ]
>
> Revised behavior not to scale:
> <- [ Conc GC ] -> <- [ Degen ] -> <- [ Conc GC ] -> [ Degen ]
> [ experiences ] [ with ] [ experiences ] [ with ]
> [ allocation ] [ bad ] [ allocation ] [ good ]
> [ failure ] [ progress ] [ failure ] [ progress ]
> [ 100 ms ] [ 100 ms ]
> [ pause ] [ pause ]
This pull request has now been integrated.
Changeset: eec76d7b
Author: Kelvin Nilsen <kdnilsen at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/eec76d7b8c4c8a64593d85338225906c188f679c
Stats: 20 lines in 3 files changed: 0 ins; 7 del; 13 mod
8377180: Shenandoah: make escalation from degen to full more conservative
Reviewed-by: wkemper, xpeng
-------------
PR: https://git.openjdk.org/jdk/pull/29574
More information about the hotspot-gc-dev
mailing list