Index: test/cctest/test-heap.cc |
diff --git a/test/cctest/test-heap.cc b/test/cctest/test-heap.cc |
index c3f8ab5aafb0be9313068da7e2050b0cea9a2226..7fa2a99327383413c1ac0cec25142075ee6fde0d 100644 |
--- a/test/cctest/test-heap.cc |
+++ b/test/cctest/test-heap.cc |
@@ -44,8 +44,8 @@ using namespace v8::internal; |
static void SimulateIncrementalMarking() { |
MarkCompactCollector* collector = CcTest::heap()->mark_compact_collector(); |
IncrementalMarking* marking = CcTest::heap()->incremental_marking(); |
- if (collector->sweeping_in_progress()) { |
- collector->EnsureSweepingCompleted(); |
+ if (collector->IsConcurrentSweepingInProgress()) { |
+ collector->WaitUntilSweepingCompleted(); |
} |
CHECK(marking->IsMarking() || marking->IsStopped()); |
if (marking->IsStopped()) { |
@@ -1595,8 +1595,8 @@ TEST(TestSizeOfObjects) { |
CcTest::heap()->CollectAllGarbage(Heap::kNoGCFlags); |
CcTest::heap()->CollectAllGarbage(Heap::kNoGCFlags); |
MarkCompactCollector* collector = CcTest::heap()->mark_compact_collector(); |
- if (collector->sweeping_in_progress()) { |
- collector->EnsureSweepingCompleted(); |
+ if (collector->IsConcurrentSweepingInProgress()) { |
+ collector->WaitUntilSweepingCompleted(); |
} |
int initial_size = static_cast<int>(CcTest::heap()->SizeOfObjects()); |
@@ -1622,8 +1622,8 @@ TEST(TestSizeOfObjects) { |
CHECK_EQ(initial_size, static_cast<int>(CcTest::heap()->SizeOfObjects())); |
// Waiting for sweeper threads should not change heap size. |
- if (collector->sweeping_in_progress()) { |
- collector->EnsureSweepingCompleted(); |
+ if (collector->IsConcurrentSweepingInProgress()) { |
+ collector->WaitUntilSweepingCompleted(); |
} |
CHECK_EQ(initial_size, static_cast<int>(CcTest::heap()->SizeOfObjects())); |
} |