RFR: 8311602 GenShen: Decouple generational mode heuristics [v2]
Kelvin Nilsen
kdnilsen at openjdk.org
Mon Jul 10 22:51:28 UTC 2023
On Mon, 10 Jul 2023 17:42:19 GMT, William Kemper <wkemper at openjdk.org> wrote:
>> The general idea here is to straighten out code paths which fork based on the mode configuration. A `ShenandoahYoungHeuristics` class has been added to host the logic specific to the generational mode. In many cases, the entangled generational code can simply be moved behind methods which override existing virtual methods.
>>
>> A few other notable changes:
>> * The confusing "trigger" heuristic has been removed from `ShenandoahOldHeuristics`.
>> * The old heuristic defines its own triggers now. It is no longer possible to specify the old generation's trigger heuristic.
>> * Selection of aged regions for in-place promotion has been moved to `ShenandoahGeneration`.
>> * The method implementation does not depend on any members of `ShenandoahHeuristics`. Moving the method therefore removes an unnecessary dependency on the heuristics.
>> * A new `ShenandoahHeapCharacteristics` interface has been added to provide information about the heap _or generation_ to the heuristics.
>> * On the development branch, this interface is implemented by `ShenandoahGeneration`.
>> * The plan is to upstream this interface and have it implemented by `ShenandoahHeap`
>>
>> The taxonomy of these heuristic classes has become somewhat more complex - here is a chart showing the relationships:
>>
>>
>> ShenandoahHeuristics
>> - ShenandoahPassiveHeuristics
>> - ShenandoahCompactHeuristics
>> - ShenandoahAggressiveHeuristics
>> - ShenandoahStaticHeuristics
>> - ShenandoahOldHeuristics
>> + ShenandoahAdaptiveHeuristics
>> + ShenandoahGenerationalHeuristics
>> - ShenandoahYoungHeuristics
>> - ShenandoahGlobalHeuristics
>
> William Kemper has updated the pull request incrementally with two additional commits since the last revision:
>
> - Remove overzealous assert
> - Fix missing imports (windows build failure)
Ok. That assert can be addressed under the other ticket.
-------------
PR Comment: https://git.openjdk.org/shenandoah/pull/292#issuecomment-1629833012
More information about the shenandoah-dev
mailing list