RFR: 8341334: CDS: Parallel pretouch and relocation [v6]

Aleksey Shipilev shade at openjdk.org
Tue Nov 5 16:11:35 UTC 2024


On Tue, 5 Nov 2024 14:56:36 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

>> Aleksey Shipilev has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains eight additional commits since the last revision:
>> 
>>  - Merge branch 'master' into JDK-8341334-cds-parallel-relocation
>>  - Make sure we gracefully shutdown whatever happens, refix shutdown race
>>  - Simpler bitmap distribution
>>  - Capitalize constants
>>  - Do not create worker threads too early: Mac/Windows are not yet ready to use Semaphores
>>  - Don't change the patching order in -ArchiveParallelIteration case
>>  - Flags
>>  - Work
>
> src/hotspot/share/cds/filemap.cpp line 1992:
> 
>> 1990:     bm->iterate(reloc, start, end);
>> 1991:   }
>> 1992: };
> 
> I wondered why you did not do a SharedDataRelocationTask with a single bitmap and a single relocator, then did that task twice, once with ro region, once for rw region. 
> 
> But I assume you want to save the communication overhead per run_task.

Yeah, while the pool is fast, I think we do not want to take chances with spinning tasks up/down and coordinating them, if we can avoid it. Putting the work into single task avoids it. Task handoff to auxiliary threads is never completely free.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21302#discussion_r1829627397


More information about the hotspot-runtime-dev mailing list