| Index: src/incremental-marking.cc
|
| diff --git a/src/incremental-marking.cc b/src/incremental-marking.cc
|
| index 8fe89b4a98c4500ed5527fd602ab55793e21896a..bfc22fd5851a83db274e15c4944977b4502e894f 100644
|
| --- a/src/incremental-marking.cc
|
| +++ b/src/incremental-marking.cc
|
| @@ -743,7 +743,7 @@ void IncrementalMarking::Finalize() {
|
| }
|
|
|
|
|
| -void IncrementalMarking::MarkingComplete() {
|
| +void IncrementalMarking::MarkingComplete(Finalizer finalizer) {
|
| state_ = COMPLETE;
|
| // We will set the stack guard to request a GC now. This will mean the rest
|
| // of the GC gets performed as soon as possible (we can't do a GC here in a
|
| @@ -754,13 +754,13 @@ void IncrementalMarking::MarkingComplete() {
|
| if (FLAG_trace_incremental_marking) {
|
| PrintF("[IncrementalMarking] Complete (normal).\n");
|
| }
|
| - if (!heap_->idle_notification_will_schedule_next_gc()) {
|
| + if (finalizer == GC_VIA_STACK_GUARD) {
|
| heap_->isolate()->stack_guard()->RequestGC();
|
| }
|
| }
|
|
|
|
|
| -void IncrementalMarking::Step(intptr_t allocated_bytes) {
|
| +void IncrementalMarking::Step(intptr_t allocated_bytes, Finalizer finalizer) {
|
| if (heap_->gc_state() != Heap::NOT_IN_GC ||
|
| !FLAG_incremental_marking ||
|
| !FLAG_incremental_marking_steps ||
|
| @@ -833,7 +833,7 @@ void IncrementalMarking::Step(intptr_t allocated_bytes) {
|
| Marking::MarkBlack(obj_mark_bit);
|
| MemoryChunk::IncrementLiveBytesFromGC(obj->address(), size);
|
| }
|
| - if (marking_deque_.IsEmpty()) MarkingComplete();
|
| + if (marking_deque_.IsEmpty()) MarkingComplete(finalizer);
|
| }
|
|
|
| allocated_ = 0;
|
|
|