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

Side by Side Diff: runtime/vm/snapshot.h

Issue 387993007: 5% smaller snapshots by omitting object ids when possible (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/dart_api_message.cc ('k') | runtime/vm/snapshot.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_SNAPSHOT_H_ 5 #ifndef VM_SNAPSHOT_H_
6 #define VM_SNAPSHOT_H_ 6 #define VM_SNAPSHOT_H_
7 7
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/allocation.h" 9 #include "vm/allocation.h"
10 #include "vm/bitfield.h" 10 #include "vm/bitfield.h"
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after
338 RawObject* ReadIndexedObject(intptr_t object_id); 338 RawObject* ReadIndexedObject(intptr_t object_id);
339 339
340 // Read an inlined object from the stream. 340 // Read an inlined object from the stream.
341 RawObject* ReadInlinedObject(intptr_t object_id); 341 RawObject* ReadInlinedObject(intptr_t object_id);
342 342
343 // Based on header field check to see if it is an internal VM class. 343 // Based on header field check to see if it is an internal VM class.
344 RawClass* LookupInternalClass(intptr_t class_header); 344 RawClass* LookupInternalClass(intptr_t class_header);
345 345
346 void ArrayReadFrom(const Array& result, intptr_t len, intptr_t tags); 346 void ArrayReadFrom(const Array& result, intptr_t len, intptr_t tags);
347 347
348 intptr_t NextAvailableObjectId() const;
349
348 Snapshot::Kind kind_; // Indicates type of snapshot(full, script, message). 350 Snapshot::Kind kind_; // Indicates type of snapshot(full, script, message).
349 Isolate* isolate_; // Current isolate. 351 Isolate* isolate_; // Current isolate.
350 Class& cls_; // Temporary Class handle. 352 Class& cls_; // Temporary Class handle.
351 Object& obj_; // Temporary Object handle. 353 Object& obj_; // Temporary Object handle.
352 Array& array_; // Temporary Array handle. 354 Array& array_; // Temporary Array handle.
353 Field& field_; // Temporary Field handle. 355 Field& field_; // Temporary Field handle.
354 String& str_; // Temporary String handle. 356 String& str_; // Temporary String handle.
355 Library& library_; // Temporary library handle. 357 Library& library_; // Temporary library handle.
356 AbstractType& type_; // Temporary type handle. 358 AbstractType& type_; // Temporary type handle.
357 TypeArguments& type_arguments_; // Temporary type argument handle. 359 TypeArguments& type_arguments_; // Temporary type argument handle.
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
698 private: 700 private:
699 SnapshotWriter* writer_; 701 SnapshotWriter* writer_;
700 bool as_references_; 702 bool as_references_;
701 703
702 DISALLOW_COPY_AND_ASSIGN(SnapshotWriterVisitor); 704 DISALLOW_COPY_AND_ASSIGN(SnapshotWriterVisitor);
703 }; 705 };
704 706
705 } // namespace dart 707 } // namespace dart
706 708
707 #endif // VM_SNAPSHOT_H_ 709 #endif // VM_SNAPSHOT_H_
OLDNEW
« no previous file with comments | « runtime/vm/dart_api_message.cc ('k') | runtime/vm/snapshot.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698