RFR: 8276129: PretouchTask should page-align the chunk size [v2]

Kim Barrett kbarrett at openjdk.java.net
Fri Nov 5 00:53:34 UTC 2021


On Tue, 2 Nov 2021 07:38:31 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:

>> Kim Barrett has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   use align_down_bounded
>
> src/hotspot/share/gc/shared/pretouchTask.cpp line 73:
> 
>> 71:   // Page-align the chunk size, so if start_address is also page-aligned (as
>> 72:   // is common) then there won't be any pages shared by multiple chunks.
>> 73:   chunk_size = align_down(chunk_size, page_size);
> 
> This looks like a place where align_down_bounded could be used. Something like this:
> 
> size_t chunk_size = align_down_bounded(PretouchTask::chunk_size(), page_size);

I either forgot about or never noticed that function.  Changed to use it.

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

PR: https://git.openjdk.java.net/jdk/pull/6204



More information about the hotspot-gc-dev mailing list