Index: src/heap/mark-compact.cc |
diff --git a/src/heap/mark-compact.cc b/src/heap/mark-compact.cc |
index 1a85216e3ff6ce84299081d8bbe3414b6f2a1319..81122da6213bec889b403be6180bbd21d043b46c 100644 |
--- a/src/heap/mark-compact.cc |
+++ b/src/heap/mark-compact.cc |
@@ -638,6 +638,9 @@ void MarkCompactCollector::CollectEvacuationCandidates(PagedSpace* space) { |
std::vector<LiveBytesPagePair> pages; |
pages.reserve(number_of_pages); |
+ DCHECK(!sweeping_in_progress()); |
+ DCHECK(!FLAG_concurrent_sweeping || |
+ sweeper().IsSweepingCompleted(space->identity())); |
for (Page* p : *space) { |
if (p->NeverEvacuate()) continue; |
// Invariant: Evacuation candidates are just created when marking is |