mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 19:44:41 +02:00
6962589: remove breadth first scanning code from parallel gc
Remove the breadth-first copying order from ParallelScavenge and use depth-first by default. Reviewed-by: jcoomes, ysr, johnc
This commit is contained in:
parent
3a2b2b4fd8
commit
38ab95c64b
30 changed files with 63 additions and 541 deletions
|
@ -157,10 +157,8 @@ void PSRefProcTaskExecutor::execute(ProcessTask& task)
|
|||
q->enqueue(new PSRefProcTaskProxy(task, i));
|
||||
}
|
||||
ParallelTaskTerminator terminator(
|
||||
ParallelScavengeHeap::gc_task_manager()->workers(),
|
||||
UseDepthFirstScavengeOrder ?
|
||||
(TaskQueueSetSuper*) PSPromotionManager::stack_array_depth()
|
||||
: (TaskQueueSetSuper*) PSPromotionManager::stack_array_breadth());
|
||||
ParallelScavengeHeap::gc_task_manager()->workers(),
|
||||
(TaskQueueSetSuper*) PSPromotionManager::stack_array_depth());
|
||||
if (task.marks_oops_alive() && ParallelGCThreads > 1) {
|
||||
for (uint j=0; j<ParallelGCThreads; j++) {
|
||||
q->enqueue(new StealTask(&terminator));
|
||||
|
@ -375,10 +373,8 @@ bool PSScavenge::invoke_no_policy() {
|
|||
q->enqueue(new ScavengeRootsTask(ScavengeRootsTask::code_cache));
|
||||
|
||||
ParallelTaskTerminator terminator(
|
||||
gc_task_manager()->workers(),
|
||||
promotion_manager->depth_first() ?
|
||||
(TaskQueueSetSuper*) promotion_manager->stack_array_depth()
|
||||
: (TaskQueueSetSuper*) promotion_manager->stack_array_breadth());
|
||||
gc_task_manager()->workers(),
|
||||
(TaskQueueSetSuper*) promotion_manager->stack_array_depth());
|
||||
if (ParallelGCThreads>1) {
|
||||
for (uint j=0; j<ParallelGCThreads; j++) {
|
||||
q->enqueue(new StealTask(&terminator));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue