Index: src/heap/mark-compact.cc |
diff --git a/src/heap/mark-compact.cc b/src/heap/mark-compact.cc |
index 08472e5b10448949ef761f91de3fbdaedeead34b..4db619fb34e124d17f488c2e70d87c5c84547a2e 100644 |
--- a/src/heap/mark-compact.cc |
+++ b/src/heap/mark-compact.cc |
@@ -3188,15 +3188,13 @@ bool MarkCompactCollector::Evacuator::EvacuatePage(Page* page) { |
if (FLAG_trace_evacuation) { |
PrintIsolate(heap->isolate(), |
"evacuation[%p]: page=%p new_space=%d " |
- "page_evacuation=%d executable=%d contains_age_mark=%d " |
- "live_bytes=%d time=%f\n", |
+ "page_evacuation=%d executable=%d live_bytes=%d time=%f\n", |
static_cast<void*>(this), static_cast<void*>(page), |
page->InNewSpace(), |
page->IsFlagSet(Page::PAGE_NEW_OLD_PROMOTION) || |
page->IsFlagSet(Page::PAGE_NEW_NEW_PROMOTION), |
- page->IsFlagSet(MemoryChunk::IS_EXECUTABLE), |
- page->Contains(heap->new_space()->age_mark()), |
- saved_live_bytes, evacuation_time); |
+ page->IsFlagSet(MemoryChunk::IS_EXECUTABLE), saved_live_bytes, |
+ evacuation_time); |
} |
return success; |
} |
@@ -3306,13 +3304,11 @@ void MarkCompactCollector::EvacuatePagesInParallel() { |
job.AddPage(page, &abandoned_pages); |
} |
- const Address age_mark = heap()->new_space()->age_mark(); |
for (Page* page : newspace_evacuation_candidates_) { |
live_bytes += page->LiveBytes(); |
if (!page->NeverEvacuate() && |
- (page->LiveBytes() > Evacuator::PageEvacuationThreshold()) && |
- !page->Contains(age_mark)) { |
- if (page->IsFlagSet(MemoryChunk::NEW_SPACE_BELOW_AGE_MARK)) { |
+ (page->LiveBytes() > Evacuator::PageEvacuationThreshold())) { |
+ if (page->InIntermediateGeneration()) { |
EvacuateNewSpacePageVisitor::MoveToOldSpace(page, heap()->old_space()); |
} else { |
EvacuateNewSpacePageVisitor::MoveToToSpace(page); |
@@ -3558,7 +3554,7 @@ void MarkCompactCollector::EvacuateNewSpaceAndCandidates() { |
EvacuateNewSpacePrologue(); |
EvacuatePagesInParallel(); |
- heap()->new_space()->set_age_mark(heap()->new_space()->top()); |
+ heap()->new_space()->SealIntermediateGeneration(); |
} |
UpdatePointersAfterEvacuation(); |