RFR: 8314599: [GenShen] Couple adaptive tenuring and generation size budgeting [v3]

William Kemper wkemper at openjdk.org
Tue Oct 7 16:43:19 UTC 2025


On Mon, 6 Oct 2025 22:41:42 GMT, Kelvin Nilsen <kdnilsen at openjdk.org> wrote:

>> src/hotspot/share/gc/shenandoah/shenandoahGeneration.cpp line 294:
>> 
>>> 292:   // We have to be careful in the event that SOEP is set to 100 by the user.
>>> 293:   assert(ShenandoahOldEvacRatioPercent <= 100, "Error");
>>> 294:   const size_t ratio_of_old_in_collection_set = (maximum_young_evacuation_reserve * ShenandoahOldEvacRatioPercent) / (100 - ShenandoahOldEvacRatioPercent);
>> 
>> It looks like we may get divide-by-zero in the above of ShenandoahOldEvacRatioPercent equals 100
>
> In the original code, we only compute ratio_of_old_in_collection_set if ShenandoahOldEvacRatioPercent != 100

Good catch, I'll fix this.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27632#discussion_r2411238898


More information about the hotspot-gc-dev mailing list