Chromium Code Reviews| Index: src/heap/heap.cc |
| diff --git a/src/heap/heap.cc b/src/heap/heap.cc |
| index 8802266d985654b1e4792f5cddb6fafd409e32da..3fef8567dc5e27076dd74190526e6c9c4f1f9c72 100644 |
| --- a/src/heap/heap.cc |
| +++ b/src/heap/heap.cc |
| @@ -1322,17 +1322,9 @@ bool Heap::PerformGarbageCollection( |
| isolate_->counters()->objs_since_last_young()->Set(0); |
| - if (collector != SCAVENGER) { |
| - // Callbacks that fire after this point might trigger nested GCs and |
| - // restart incremental marking, the assertion can't be moved down. |
| - DCHECK(incremental_marking()->IsStopped()); |
| - |
| - // We finished a marking cycle. We can uncommit the marking deque until |
| - // we start marking again. |
| - mark_compact_collector()->marking_deque()->Uninitialize(); |
| - mark_compact_collector()->EnsureMarkingDequeIsCommitted( |
| - MarkCompactCollector::kMinMarkingDequeSize); |
| - } |
| + // Callbacks that fire after this point might trigger nested GCs and |
| + // restart incremental marking, the assertion can't be moved down. |
| + if (collector != SCAVENGER) DCHECK(incremental_marking()->IsStopped()); |
|
Hannes Payer (out of office)
2016/03/21 11:55:22
Please move this check also into the MarkCompactEp
Marcel Hlopko
2016/03/21 12:37:42
Done.
|
| gc_post_processing_depth_++; |
| { |
| @@ -1456,6 +1448,12 @@ void Heap::MarkCompactEpilogue() { |
| incremental_marking()->Epilogue(); |
| PreprocessStackTraces(); |
| + |
| + // We finished a marking cycle. We can uncommit the marking deque until |
| + // we start marking again. |
| + mark_compact_collector()->marking_deque()->Uninitialize(); |
| + mark_compact_collector()->EnsureMarkingDequeIsCommitted( |
| + MarkCompactCollector::kMinMarkingDequeSize); |
| } |