RFR: 8316632: Shenandoah: Raise OOME when gc threshold is exceeded
Aleksey Shipilev
shade at openjdk.org
Thu Sep 21 08:00:42 UTC 2023
On Wed, 20 Sep 2023 22:41:52 GMT, William Kemper <wkemper at openjdk.org> wrote:
> Shenandoah will run back-to-back full GCs and _almost_ grind mutator progress to a halt before eventually exhausting memory. This change will have Shenandoah raise a gc threshold exceeded exception if the collector fails to make progress after `ShenandoahNoProgressThreshold` full GC cycles (default is 3).
src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp line 940:
> 938: *gc_overhead_limit_was_exceeded = false;
> 939: ShenandoahAllocRequest req = ShenandoahAllocRequest::for_shared(size);
> 940: if (get_gc_no_progress_count() > ShenandoahNoProgressThreshold) {
Move this block to `ShenandoahHeap::allocate_memory`? This would require adding a (default) argument to that method, but it is a good tradeoff for putting all mechanics around this into a single method.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15852#discussion_r1332636658
More information about the hotspot-gc-dev
mailing list