Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(251)

Unified Diff: src/heap/heap.cc

Issue 2007563004: Revert of [heap] Pass a force_promotion flag to the evacuation routine in the scavenger. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/heap/heap.h ('k') | src/heap/scavenger.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/heap.cc
diff --git a/src/heap/heap.cc b/src/heap/heap.cc
index a358feafe592c488ee1e0681da2e08790bde2945..3c8b876bf5d1e5b529001a985fe5ecabfdd92085 100644
--- a/src/heap/heap.cc
+++ b/src/heap/heap.cc
@@ -1668,18 +1668,15 @@
// Copy objects reachable from the old generation.
TRACE_GC(tracer(), GCTracer::Scope::SCAVENGER_OLD_TO_NEW_POINTERS);
RememberedSet<OLD_TO_NEW>::Iterate(this, [this](Address addr) {
- return Scavenger::CheckAndScavengeObject(this, addr, DEFAULT_PROMOTION);
+ return Scavenger::CheckAndScavengeObject(this, addr);
});
RememberedSet<OLD_TO_NEW>::IterateTyped(
this, [this](SlotType type, Address addr) {
return UpdateTypedSlotHelper::UpdateTypedSlot(
isolate(), type, addr, [this](Object** addr) {
- // We expect that objects referenced by code are long living.
- // If we do not force promotion, then we need to clear
- // old_to_new slots in dead code objects after mark-compact.
return Scavenger::CheckAndScavengeObject(
- this, reinterpret_cast<Address>(addr), FORCE_PROMOTION);
+ this, reinterpret_cast<Address>(addr));
});
});
}
@@ -4668,8 +4665,8 @@
Object* target = *slot;
if (target->IsHeapObject()) {
if (Heap::InFromSpace(target)) {
- callback(reinterpret_cast<HeapObject**>(slot), HeapObject::cast(target),
- DEFAULT_PROMOTION);
+ callback(reinterpret_cast<HeapObject**>(slot),
+ HeapObject::cast(target));
Object* new_target = *slot;
if (InNewSpace(new_target)) {
SLOW_DCHECK(Heap::InToSpace(new_target));
« no previous file with comments | « src/heap/heap.h ('k') | src/heap/scavenger.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698