RFR: 8352181: Shenandoah: Evacuate thread roots after early cleanup
Kelvin Nilsen
kdnilsen at openjdk.org
Wed Apr 2 17:55:48 UTC 2025
On Mon, 17 Mar 2025 21:37:14 GMT, William Kemper <wkemper at openjdk.org> wrote:
> Moving the evacuation of thread roots after early cleanup allows Shenandoah to recycle immediate garbage a bit sooner in the cycle.
Maybe the "best" tradeoff is "adaptive behavior". If allocatable memory is in "short supply", we should evacuate thread roots early. Otherwise, we should preserve existing behavior. Defining "short supply" might be a bit tricky.
There's a related PR that is still in development, to surge GC worker threads when we are at risk of experiencing allocation failures. A lot of heuristic predictions feed into the decision of when and whether to surge. We could use that same feedback mechanism here. If we are under "worker surge" conditions, that suggests memory is in short supply, an this is the ideal time to shift some of the GC work onto the mutators, so this is when we should evacuate thread roots early.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/24090#issuecomment-2773302505
More information about the hotspot-gc-dev
mailing list