Commit ee2d5027 authored by ulan's avatar ulan Committed by Commit bot

[heap] Prefer mark-compact over scavenger if incremental marking

needs finalization and allocation limit is reached.

BUG=

Review-Url: https://codereview.chromium.org/2561103002
Cr-Commit-Position: refs/heads/master@{#41593}
parent 9c191a0c
......@@ -264,6 +264,12 @@ GarbageCollector Heap::SelectGarbageCollector(AllocationSpace space,
return MARK_COMPACTOR;
}
if (incremental_marking()->NeedsFinalization() &&
OldGenerationSpaceAvailable() == 0) {
*reason = "Incremental marking needs finalization";
return MARK_COMPACTOR;
}
// Is there enough space left in OLD to guarantee that a scavenge can
// succeed?
//
......
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