RFR: Generation resizing

Roman Kennke rkennke at openjdk.org
Mon Dec 5 11:16:15 UTC 2022


On Sat, 3 Dec 2022 01:09:59 GMT, William Kemper <wkemper at openjdk.org> wrote:

> These changes have the generational mode track the minimum mutator utilization (percentage of process time used by mutators). When it falls below a configuration percentage (GCTimeRatio), a heuristic will transfer memory capacity to whatever generation has been using more CPU time. The assumption here is that by increasing capacity, we will decrease the collection frequency and improve the MMU.

Thank you for implementing this useful change! I have a few questions and comments.

src/hotspot/share/gc/shenandoah/shenandoahControlThread.cpp line 451:

> 449: void ShenandoahControlThread::service_concurrent_normal_cycle(
> 450:   const ShenandoahHeap* heap, const GenerationMode generation, GCCause::Cause cause) {
> 451:   GCIdMark gc_id_mark;

Why does the GCIdMark need to move around?

src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp line 1791:

> 1789: 
> 1790: void ShenandoahHeap::on_cycle_start(GCCause::Cause cause, ShenandoahGeneration* generation) {
> 1791:   log_info(gc)("on_cycle_start: %s", generation->name());

What is that logging for/ what does the log message mean? I'd either improve the log message or remove the logging (or make it dev+trace) if it was only for dev purposes.

src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp line 1804:

> 1802: 
> 1803: void ShenandoahHeap::on_cycle_end(ShenandoahGeneration* generation) {
> 1804:   log_info(gc)("on_cycle_end: %s", generation->name());

Same here.

src/hotspot/share/gc/shenandoah/shenandoahMmuTracker.cpp line 25:

> 23:  */
> 24: 
> 25: #include "gc/shenandoah/shenandoahMmuTracker.hpp"

You need to include precompiled.hpp here.

src/hotspot/share/gc/shenandoah/shenandoahMmuTracker.hpp line 28:

> 26: #define SHARE_GC_SHENANDOAH_SHENANDOAHMMUTRACKER_HPP
> 27: 
> 28: #include "memory/iterator.hpp"

What do we need the iterator.hpp for?

-------------

PR: https://git.openjdk.org/shenandoah/pull/177


More information about the shenandoah-dev mailing list