Commit 3d11bf77 authored by Gabriel Charette's avatar Gabriel Charette Committed by Commit Bot

Highlight individual work items in tracing of parallel GC.

This merely re-uses the same ScopeId as the task. Tracing shows these
as a nested layer with the same name. This is not the cleanest way to
do this but it makes the trace clearer for a minimal diff.

R=mlippautz@chromium.org

Bug: chromium:651354
Change-Id: Ib30ec7d04a30657a63a49aba9698cacd9af950d3
Reviewed-on: https://chromium-review.googlesource.com/904164
Commit-Queue: Gabriel Charette <gab@chromium.org>
Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#51120}
parent 74e754a3
......@@ -1981,6 +1981,9 @@ class ScavengingTask final : public ItemParallelJob::Task {
TimedScope scope(&scavenging_time);
PageScavengingItem* item = nullptr;
while ((item = GetItem<PageScavengingItem>()) != nullptr) {
TRACE_BACKGROUND_GC(
heap_->tracer(),
GCTracer::BackgroundScope::SCAVENGER_BACKGROUND_SCAVENGE_PARALLEL);
item->Process(scavenger_);
item->MarkFinished();
}
......
......@@ -1818,6 +1818,9 @@ class YoungGenerationMarkingTask : public ItemParallelJob::Task {
TimedScope scope(&marking_time);
MarkingItem* item = nullptr;
while ((item = GetItem<MarkingItem>()) != nullptr) {
TRACE_BACKGROUND_GC(
collector_->heap()->tracer(),
GCTracer::BackgroundScope::MINOR_MC_BACKGROUND_MARKING);
item->Process(this);
item->MarkFinished();
EmptyLocalMarkingWorklist();
......@@ -3204,6 +3207,7 @@ class PageEvacuationTask : public ItemParallelJob::Task {
TRACE_BACKGROUND_GC(tracer_, evacuator_->GetBackgroundTracingScope());
PageEvacuationItem* item = nullptr;
while ((item = GetItem<PageEvacuationItem>()) != nullptr) {
TRACE_BACKGROUND_GC(tracer_, evacuator_->GetBackgroundTracingScope());
evacuator_->EvacuatePage(item->page());
item->MarkFinished();
}
......@@ -3520,6 +3524,7 @@ class PointersUpdatingTask : public ItemParallelJob::Task {
TRACE_BACKGROUND_GC(tracer_, scope_);
UpdatingItem* item = nullptr;
while ((item = GetItem<UpdatingItem>()) != nullptr) {
TRACE_BACKGROUND_GC(tracer_, scope_);
item->Process();
item->MarkFinished();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment