| OLD | NEW |
| 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_OBJECT_H_ | 5 #ifndef VM_OBJECT_H_ |
| 6 #define VM_OBJECT_H_ | 6 #define VM_OBJECT_H_ |
| 7 | 7 |
| 8 #include "include/dart_api.h" | 8 #include "include/dart_api.h" |
| 9 #include "platform/assert.h" | 9 #include "platform/assert.h" |
| 10 #include "platform/utils.h" | 10 #include "platform/utils.h" |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 Snapshot::Kind); \ | 124 Snapshot::Kind); \ |
| 125 friend class SnapshotReader; \ | 125 friend class SnapshotReader; \ |
| 126 | 126 |
| 127 #define HEAP_OBJECT_IMPLEMENTATION(object, super) \ | 127 #define HEAP_OBJECT_IMPLEMENTATION(object, super) \ |
| 128 OBJECT_IMPLEMENTATION(object, super); \ | 128 OBJECT_IMPLEMENTATION(object, super); \ |
| 129 Raw##object* raw_ptr() const { \ | 129 Raw##object* raw_ptr() const { \ |
| 130 ASSERT(raw() != null()); \ | 130 ASSERT(raw() != null()); \ |
| 131 return raw()->ptr(); \ | 131 return raw()->ptr(); \ |
| 132 } \ | 132 } \ |
| 133 SNAPSHOT_READER_SUPPORT(object) \ | 133 SNAPSHOT_READER_SUPPORT(object) \ |
| 134 friend class DartFrame; \ | 134 friend class StackFrame; \ |
| 135 | 135 |
| 136 class Object { | 136 class Object { |
| 137 public: | 137 public: |
| 138 // Index for Singleton internal VM classes, | 138 // Index for Singleton internal VM classes, |
| 139 // this index is used in snapshots to refer to these classes directly. | 139 // this index is used in snapshots to refer to these classes directly. |
| 140 enum { | 140 enum { |
| 141 kNullObject = 0, | 141 kNullObject = 0, |
| 142 kSentinelObject, | 142 kSentinelObject, |
| 143 kClassClass, | 143 kClassClass, |
| 144 kNullClass, | 144 kNullClass, |
| (...skipping 3855 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4000 } | 4000 } |
| 4001 | 4001 |
| 4002 | 4002 |
| 4003 intptr_t Stackmap::SizeInBits() const { | 4003 intptr_t Stackmap::SizeInBits() const { |
| 4004 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); | 4004 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); |
| 4005 } | 4005 } |
| 4006 | 4006 |
| 4007 } // namespace dart | 4007 } // namespace dart |
| 4008 | 4008 |
| 4009 #endif // VM_OBJECT_H_ | 4009 #endif // VM_OBJECT_H_ |
| OLD | NEW |