Index: runtime/vm/snapshot.cc |
=================================================================== |
--- runtime/vm/snapshot.cc (revision 37600) |
+++ runtime/vm/snapshot.cc (working copy) |
@@ -302,7 +302,8 @@ |
} |
// For all other internal VM classes we read the object inline. |
- intptr_t tags = ReadIntptrValue(); |
+ intptr_t tags = ReadTags(); |
+ tags = RawObject::ClassIdTag::update(class_id, tags); |
siva
2014/06/23 21:45:53
Is it necessary to or in the class_id here? I thin
zra
2014/06/23 22:17:50
The class id is taken from tags in TypedData::Read
|
switch (class_id) { |
#define SNAPSHOT_READ(clazz) \ |
case clazz::kClassId: { \ |
@@ -812,7 +813,7 @@ |
RawObject* SnapshotReader::ReadInlinedObject(intptr_t object_id) { |
// Read the class header information and lookup the class. |
intptr_t class_header = ReadIntptrValue(); |
- intptr_t tags = ReadIntptrValue(); |
+ intptr_t tags = ReadTags(); |
if (SerializedHeaderData::decode(class_header) == kInstanceObjectId) { |
// Object is regular dart instance. |
Instance* result = reinterpret_cast<Instance*>(GetBackRef(object_id)); |
@@ -880,6 +881,7 @@ |
ASSERT((class_header & kSmiTagMask) != kSmiTag); |
cls_ = LookupInternalClass(class_header); |
ASSERT(!cls_.IsNull()); |
+ tags = RawObject::ClassIdTag::update(cls_.id(), tags); |
siva
2014/06/23 21:45:53
Ditto comment about oring in the class_id
zra
2014/06/23 22:17:50
Same as above.
|
switch (cls_.id()) { |
#define SNAPSHOT_READ(clazz) \ |
case clazz::kClassId: { \ |
@@ -1388,7 +1390,7 @@ |
// case. |
// Write out the class and tags information. |
WriteVMIsolateObject(kClassCid); |
- WriteIntptrValue(GetObjectTags(cls)); |
+ WriteTags(GetObjectTags(cls)); |
// Write out the library url and class name. |
RawLibrary* library = cls->ptr()->library_; |
@@ -1411,7 +1413,7 @@ |
// Write out the class and tags information. |
WriteIndexedObject(array_kind); |
- WriteIntptrValue(tags); |
+ WriteTags(tags); |
// Write out the length field. |
Write<RawObject*>(length); |
@@ -1471,7 +1473,7 @@ |
WriteIntptrValue(SerializedHeaderData::encode(kInstanceObjectId)); |
// Write out the tags. |
- WriteIntptrValue(tags); |
+ WriteTags(tags); |
// Write out the class information for this object. |
WriteObjectImpl(cls); |