Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1578)

Unified Diff: src/heap/incremental-marking.cc

Issue 2371733002: Introduce EmbedderReachableReferenceReporter (Closed)
Patch Set: Fix UsingEmbedderHeapTracer Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/heap/heap.cc ('k') | src/heap/mark-compact.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/incremental-marking.cc
diff --git a/src/heap/incremental-marking.cc b/src/heap/incremental-marking.cc
index 0dcce20e7bd8cd1efa70a84ca2ab32ee9ec6888d..5db451ad495eed98d50b978d3584a6965f2cef4e 100644
--- a/src/heap/incremental-marking.cc
+++ b/src/heap/incremental-marking.cc
@@ -569,7 +569,8 @@ void IncrementalMarking::StartMarking() {
if (heap_->UsingEmbedderHeapTracer()) {
TRACE_GC(heap()->tracer(),
GCTracer::Scope::MC_INCREMENTAL_WRAPPER_PROLOGUE);
- heap_->mark_compact_collector()->embedder_heap_tracer()->TracePrologue();
+ heap_->embedder_heap_tracer()->TracePrologue(
+ heap_->embedder_reachable_reference_reporter());
}
RecordWriteStub::Mode mode = is_compacting_
@@ -796,8 +797,7 @@ void IncrementalMarking::FinalizeIncrementally() {
abs(old_marking_deque_top -
heap_->mark_compact_collector()->marking_deque()->top());
- marking_progress +=
- static_cast<int>(heap_->mark_compact_collector()->wrappers_to_trace());
+ marking_progress += static_cast<int>(heap_->wrappers_to_trace());
double end = heap_->MonotonicallyIncreasingTimeInMs();
double delta = end - start;
@@ -1226,8 +1226,7 @@ void IncrementalMarking::Step(intptr_t bytes_to_process,
FLAG_incremental_marking_wrappers && heap_->UsingEmbedderHeapTracer();
const bool process_wrappers =
incremental_wrapper_tracing &&
- (heap_->mark_compact_collector()
- ->RequiresImmediateWrapperProcessing() ||
+ (heap_->RequiresImmediateWrapperProcessing() ||
heap_->mark_compact_collector()->marking_deque()->IsEmpty());
bool wrapper_work_left = incremental_wrapper_tracing;
if (!process_wrappers) {
@@ -1248,14 +1247,11 @@ void IncrementalMarking::Step(intptr_t bytes_to_process,
heap_->MonotonicallyIncreasingTimeInMs() + kStepSizeInMs;
TRACE_GC(heap()->tracer(),
GCTracer::Scope::MC_INCREMENTAL_WRAPPER_TRACING);
- heap_->mark_compact_collector()->RegisterWrappersWithEmbedderHeapTracer();
- wrapper_work_left =
- heap_->mark_compact_collector()
- ->embedder_heap_tracer()
- ->AdvanceTracing(wrapper_deadline,
- EmbedderHeapTracer::AdvanceTracingActions(
- EmbedderHeapTracer::ForceCompletionAction::
- DO_NOT_FORCE_COMPLETION));
+ heap_->RegisterWrappersWithEmbedderHeapTracer();
+ wrapper_work_left = heap_->embedder_heap_tracer()->AdvanceTracing(
+ wrapper_deadline, EmbedderHeapTracer::AdvanceTracingActions(
+ EmbedderHeapTracer::ForceCompletionAction::
+ DO_NOT_FORCE_COMPLETION));
}
if (heap_->mark_compact_collector()->marking_deque()->IsEmpty() &&
« no previous file with comments | « src/heap/heap.cc ('k') | src/heap/mark-compact.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698