RFR: 8365880: Shenandoah: Unify memory usage accounting in ShenandoahFreeSet [v12]

Kelvin Nilsen kdnilsen at openjdk.org
Tue Oct 7 21:50:03 UTC 2025


On Thu, 2 Oct 2025 23:43:00 GMT, William Kemper <wkemper at openjdk.org> wrote:

>> Kelvin Nilsen has updated the pull request incrementally with five additional commits since the last revision:
>> 
>>  - small refactoring
>>  - OO refinements to used_regions_size()
>>  - fix broken assert from previous commit
>>  - OO refinements to free_unaffiliated_regions()
>>  - OO refinements to max_capacity()
>
> src/hotspot/share/gc/shenandoah/shenandoahHeap.cpp line 2719:
> 
>> 2717:   assert(used() <= ShenandoahHeap::heap()->max_capacity(), "sanity");
>> 2718:   assert(committed() <= ShenandoahHeap::heap()->max_capacity(), "sanity");
>> 2719:   assert(max_capacity() <= ShenandoahHeap::heap()->max_capacity(), "sanity");
> 
> This last one is just comparing the results of the same method call. Are we worried about races here?

Removing that one.  Don't know what I was thinking...

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

PR Review Comment: https://git.openjdk.org/jdk/pull/26867#discussion_r2412004168


More information about the hotspot-gc-dev mailing list