Commit 4975ac41 authored by ulan's avatar ulan Committed by Commit bot

[heap] Respect the old generation max limit when moving new space pages.

BUG=

Review-Url: https://codereview.chromium.org/2672503002
Cr-Commit-Position: refs/heads/master@{#42866}
parent b7df78f3
......@@ -3291,7 +3291,8 @@ void MarkCompactCollector::EvacuatePagesInParallel() {
live_bytes += page->LiveBytes();
if (!reduce_memory && !page->NeverEvacuate() &&
(page->LiveBytes() > Evacuator::PageEvacuationThreshold()) &&
!page->Contains(age_mark)) {
!page->Contains(age_mark) &&
heap()->CanExpandOldGeneration(page->LiveBytes())) {
if (page->IsFlagSet(MemoryChunk::NEW_SPACE_BELOW_AGE_MARK)) {
EvacuateNewSpacePageVisitor<NEW_TO_OLD>::Move(page);
} else {
......
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