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

Unified Diff: src/serialize.cc

Issue 2950003: Virtually dispatched scavengers (Closed)
Patch Set: Created 10 years, 5 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/objects-inl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/serialize.cc
diff --git a/src/serialize.cc b/src/serialize.cc
index a6a516a76d5ceb5896c47eb8bb4e76e282fd5659..e8aed5496f14dd0061760b3c20c60e2e32ebe19c 100644
--- a/src/serialize.cc
+++ b/src/serialize.cc
@@ -673,6 +673,14 @@ void Deserializer::ReadObject(int space_number,
LOG(SnapshotPositionEvent(address, source_->position()));
}
ReadChunk(current, limit, space_number, address);
+
+ if (space == Heap::map_space()) {
+ ASSERT(size == Map::kSize);
+ HeapObject* obj = HeapObject::FromAddress(address);
+ Map* map = reinterpret_cast<Map*>(obj);
+ map->set_scavenger(Heap::GetScavenger(map->instance_type(),
+ map->instance_size()));
+ }
}
« no previous file with comments | « src/objects-inl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698