RFR: 8255984: Shenandoah: "adaptive" heuristic is prone to missing load spikes [v2]
Aleksey Shipilev
shade at openjdk.java.net
Mon Nov 16 08:23:00 UTC 2020
On Fri, 13 Nov 2020 22:24:22 GMT, earthling-amzn <github.com+71722661+earthling-amzn at openjdk.org> wrote:
>> earthling-amzn has updated the pull request incrementally with two additional commits since the last revision:
>>
>> - Remove const qualifier from should_start_gc
>>
>> This lets the heuristics update state without const_casts.
>> - Rename ShenandoahReactive flags to ShenandoahAdaptive flags.
>
> src/hotspot/share/gc/shenandoah/heuristics/shenandoahAdaptiveHeuristics.cpp line 335:
>
>> 333: _last_sample_value(0),
>> 334: _interval_ns(NANOUNITS / ShenandoahAdaptiveSampleFrequencyHz),
>> 335: _rate(ShenandoahAdaptiveSampleSizeSeconds * ShenandoahAdaptiveSampleFrequencyHz, ShenandoahAdaptiveDecayFactor),
>
> I get a warning here because `TruncatedSeq` constructor takes a signed `int` for length (SampleSize and Frequency are unsigned). Could we change that constructor?
We better not. I think it is fine to have explicit cast to `int` to avoid this warning.
-------------
PR: https://git.openjdk.java.net/jdk/pull/1099
More information about the shenandoah-dev
mailing list