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

Unified Diff: runtime/vm/snapshot.cc

Issue 1377543003: Clean up serialization of RawFunction, RawCode (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: as-reference Created 5 years, 3 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
« runtime/vm/raw_object_snapshot.cc ('K') | « runtime/vm/snapshot.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/snapshot.cc
diff --git a/runtime/vm/snapshot.cc b/runtime/vm/snapshot.cc
index c7086a419da76d7e3e5ff32a68ab812d7dcd731f..5875720e09df701fb0bfdd1a4dc64775c5be295e 100644
--- a/runtime/vm/snapshot.cc
+++ b/runtime/vm/snapshot.cc
@@ -2229,14 +2229,7 @@ void SnapshotWriter::WriteObjectImpl(RawObject* raw, bool as_reference) {
// Objects are usually writen as references to avoid deep recursion, but in
// some places we know we are dealing with leaf or shallow objects and write
// them inline.
- // Code and Instructions are written inline so that Functions and Code
- // can patch their entry points in their ReadFrom's. TODO(rmacnak): Remove the
- // special case for Code and Instructions and patch entries after the whole
- // graph has been loaded.
- if (!as_reference ||
- raw->IsCanonical() ||
- raw->IsCode() ||
- raw->IsInstructions()) {
+ if (!as_reference || raw->IsCanonical()) {
// Object is being serialized, add it to the forward ref list and mark
// it so that future references to this object in the snapshot will use
// an object id, instead of trying to serialize it again.
« runtime/vm/raw_object_snapshot.cc ('K') | « runtime/vm/snapshot.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698