| 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 4897 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4908 Heap* isolate_heap = isolate->heap(); | 4908 Heap* isolate_heap = isolate->heap(); |
| 4909 Heap* vm_isolate_heap = Dart::vm_isolate()->heap(); | 4909 Heap* vm_isolate_heap = Dart::vm_isolate()->heap(); |
| 4910 ASSERT(isolate_heap->Contains(reinterpret_cast<uword>(raw_->ptr())) || | 4910 ASSERT(isolate_heap->Contains(reinterpret_cast<uword>(raw_->ptr())) || |
| 4911 vm_isolate_heap->Contains(reinterpret_cast<uword>(raw_->ptr()))); | 4911 vm_isolate_heap->Contains(reinterpret_cast<uword>(raw_->ptr()))); |
| 4912 #endif | 4912 #endif |
| 4913 if (raw_ == null_) { | 4913 if (raw_ == null_) { |
| 4914 set_vtable(handle_vtable_); | 4914 set_vtable(handle_vtable_); |
| 4915 } else { | 4915 } else { |
| 4916 intptr_t cid = raw_->GetClassId(); | 4916 intptr_t cid = raw_->GetClassId(); |
| 4917 if (cid < kNumPredefinedKinds) { | 4917 if (cid < kNumPredefinedKinds) { |
| 4918 #if defined(DEBUG) |
| 4918 ASSERT(builtin_vtables_[cid] == | 4919 ASSERT(builtin_vtables_[cid] == |
| 4919 isolate->class_table()->At(cid)->ptr()->handle_vtable_); | 4920 isolate->class_table()->At(cid)->ptr()->handle_vtable_); |
| 4921 #endif |
| 4920 set_vtable(builtin_vtables_[cid]); | 4922 set_vtable(builtin_vtables_[cid]); |
| 4921 } else { | 4923 } else { |
| 4922 #if !defined(DEBUG) | 4924 #if !defined(DEBUG) |
| 4923 Isolate* isolate = Isolate::Current(); | 4925 Isolate* isolate = Isolate::Current(); |
| 4924 #endif | 4926 #endif |
| 4925 RawClass* raw_class = isolate->class_table()->At(cid); | 4927 RawClass* raw_class = isolate->class_table()->At(cid); |
| 4926 set_vtable(raw_class->ptr()->handle_vtable_); | 4928 set_vtable(raw_class->ptr()->handle_vtable_); |
| 4927 } | 4929 } |
| 4928 } | 4930 } |
| 4929 } | 4931 } |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4971 } | 4973 } |
| 4972 | 4974 |
| 4973 | 4975 |
| 4974 intptr_t Stackmap::SizeInBits() const { | 4976 intptr_t Stackmap::SizeInBits() const { |
| 4975 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); | 4977 return (Smi::Value(raw_ptr()->bitmap_size_in_bytes_) * kBitsPerByte); |
| 4976 } | 4978 } |
| 4977 | 4979 |
| 4978 } // namespace dart | 4980 } // namespace dart |
| 4979 | 4981 |
| 4980 #endif // VM_OBJECT_H_ | 4982 #endif // VM_OBJECT_H_ |
| OLD | NEW |