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 4146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4157 } | 4157 } |
4158 | 4158 |
4159 intptr_t Length() const { return raw_ptr()->length_; } | 4159 intptr_t Length() const { return raw_ptr()->length_; } |
4160 | 4160 |
4161 uint32_t PcOffset() const { return raw_ptr()->pc_offset_; } | 4161 uint32_t PcOffset() const { return raw_ptr()->pc_offset_; } |
4162 void SetPcOffset(uint32_t value) const { | 4162 void SetPcOffset(uint32_t value) const { |
4163 ASSERT(value <= kMaxUint32); | 4163 ASSERT(value <= kMaxUint32); |
4164 StoreNonPointer(&raw_ptr()->pc_offset_, value); | 4164 StoreNonPointer(&raw_ptr()->pc_offset_, value); |
4165 } | 4165 } |
4166 | 4166 |
4167 intptr_t RegisterBitCount() const { return raw_ptr()->register_bit_count_; } | 4167 intptr_t SlowPathBitCount() const { return raw_ptr()->slow_path_bit_count_; } |
4168 void SetRegisterBitCount(intptr_t register_bit_count) const { | 4168 void SetSlowPathBitCount(intptr_t bit_count) const { |
4169 ASSERT(register_bit_count < kMaxInt32); | 4169 ASSERT(bit_count < kMaxInt32); |
4170 StoreNonPointer(&raw_ptr()->register_bit_count_, register_bit_count); | 4170 StoreNonPointer(&raw_ptr()->slow_path_bit_count_, bit_count); |
4171 } | 4171 } |
4172 | 4172 |
4173 bool Equals(const Stackmap& other) const { | 4173 bool Equals(const Stackmap& other) const { |
4174 if (Length() != other.Length()) { | 4174 if (Length() != other.Length()) { |
4175 return false; | 4175 return false; |
4176 } | 4176 } |
4177 NoSafepointScope no_safepoint; | 4177 NoSafepointScope no_safepoint; |
4178 return memcmp(raw_ptr(), other.raw_ptr(), InstanceSize(Length())) == 0; | 4178 return memcmp(raw_ptr(), other.raw_ptr(), InstanceSize(Length())) == 0; |
4179 } | 4179 } |
4180 | 4180 |
(...skipping 4312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8493 | 8493 |
8494 | 8494 |
8495 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, | 8495 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, |
8496 intptr_t index) { | 8496 intptr_t index) { |
8497 return array.At((index * kEntryLength) + kTargetFunctionIndex); | 8497 return array.At((index * kEntryLength) + kTargetFunctionIndex); |
8498 } | 8498 } |
8499 | 8499 |
8500 } // namespace dart | 8500 } // namespace dart |
8501 | 8501 |
8502 #endif // VM_OBJECT_H_ | 8502 #endif // VM_OBJECT_H_ |
OLD | NEW |