RFR: Add generations to freeset [v5]

Kelvin Nilsen kdnilsen at openjdk.org
Tue Apr 18 21:51:37 UTC 2023


On Thu, 13 Apr 2023 01:36:29 GMT, Y. Srinivas Ramakrishna <ysr at openjdk.org> wrote:

>> Kelvin Nilsen has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Remove debug instrumentation
>
> src/hotspot/share/gc/shenandoah/shenandoahFreeSet.hpp line 116:
> 
>> 114:   ShenandoahFreeSet(ShenandoahHeap* heap, size_t max_regions);
>> 115: 
>> 116:   // Number of regions dedicated to GC allocations (for evacuation) that are currently free
> 
> In the generational case, are these the free (i.e. completely empty and not yet allocated) regions dedicated for use by only the young collector? If so, why not call it `young_collector_count()` consistent with `old_collector_count()` below?
> 
> Similarly for the underlying bitmap as well to `_young_collector_free_bitmap`?
> 
> Or is it the case that this is also used for the non-generational setting as well and hence the name without the `young` prefix, cf the `old` prefix below?

In all three cases, this is the number of regions dedicated to "the cause" that are at "partially free".  These regions are not necessarily "fully free".  I've modified the comments to reflect such.

The name "collector_free" is historical.  This predates generational Shenandoah and it is still used for "non-generational mode" of Shenandoah.  I'm inclined to leave it as is.  Though I am quite willing to make the change if that is the "consensus" position.

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

PR Review Comment: https://git.openjdk.org/shenandoah/pull/250#discussion_r1170601183


More information about the shenandoah-dev mailing list