Commit b54c1a6e authored by Ulan Degenbaev's avatar Ulan Degenbaev Committed by Commit Bot

[heap] Ensure that sweeping is completed in ConcurrentMarking cctests.

Bug: chromium:694255
Change-Id: I5dc6157126544f20bca0ddee967e1d08d69bb060
Reviewed-on: https://chromium-review.googlesource.com/707104Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#48380}
parent 12008bcc
......@@ -33,6 +33,10 @@ TEST(ConcurrentMarking) {
Heap* heap = CcTest::heap();
CcTest::CollectAllGarbage();
if (!heap->incremental_marking()->IsStopped()) return;
MarkCompactCollector* collector = CcTest::heap()->mark_compact_collector();
if (collector->sweeping_in_progress()) {
collector->EnsureSweepingCompleted();
}
ConcurrentMarking::MarkingWorklist shared, bailout;
WeakObjects weak_objects;
ConcurrentMarking* concurrent_marking =
......@@ -49,6 +53,11 @@ TEST(ConcurrentMarkingReschedule) {
Heap* heap = CcTest::heap();
CcTest::CollectAllGarbage();
if (!heap->incremental_marking()->IsStopped()) return;
MarkCompactCollector* collector = CcTest::heap()->mark_compact_collector();
if (collector->sweeping_in_progress()) {
collector->EnsureSweepingCompleted();
}
ConcurrentMarking::MarkingWorklist shared, bailout;
WeakObjects weak_objects;
ConcurrentMarking* concurrent_marking =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment