OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_TYPE_FEEDBACK_VECTOR_H_ | 5 #ifndef V8_TYPE_FEEDBACK_VECTOR_H_ |
6 #define V8_TYPE_FEEDBACK_VECTOR_H_ | 6 #define V8_TYPE_FEEDBACK_VECTOR_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "src/base/logging.h" | 10 #include "src/base/logging.h" |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 | 215 |
216 typedef BitSetComputer<FeedbackVectorSlotKind, kFeedbackVectorSlotKindBits, | 216 typedef BitSetComputer<FeedbackVectorSlotKind, kFeedbackVectorSlotKindBits, |
217 kSmiValueSize, uint32_t> VectorICComputer; | 217 kSmiValueSize, uint32_t> VectorICComputer; |
218 | 218 |
219 DISALLOW_IMPLICIT_CONSTRUCTORS(TypeFeedbackMetadata); | 219 DISALLOW_IMPLICIT_CONSTRUCTORS(TypeFeedbackMetadata); |
220 }; | 220 }; |
221 | 221 |
222 | 222 |
223 // The shape of the TypeFeedbackVector is an array with: | 223 // The shape of the TypeFeedbackVector is an array with: |
224 // 0: feedback metadata | 224 // 0: feedback metadata |
225 // 1: ics_with_types | 225 // 1: feedback slot #0 |
226 // 2: ics_with_generic_info | |
227 // 3: feedback slot #0 | |
228 // ... | 226 // ... |
229 // 3 + slot_count - 1: feedback slot #(slot_count-1) | 227 // 1 + slot_count - 1: feedback slot #(slot_count-1) |
230 // | 228 // |
231 class TypeFeedbackVector : public FixedArray { | 229 class TypeFeedbackVector : public FixedArray { |
232 public: | 230 public: |
233 // Casting. | 231 // Casting. |
234 static inline TypeFeedbackVector* cast(Object* obj); | 232 static inline TypeFeedbackVector* cast(Object* obj); |
235 | 233 |
236 static const int kMetadataIndex = 0; | 234 static const int kMetadataIndex = 0; |
237 static const int kReservedIndexCount = 1; | 235 static const int kReservedIndexCount = 1; |
238 | 236 |
239 inline void ComputeCounts(int* with_type_info, int* generic); | 237 inline void ComputeCounts(int* with_type_info, int* generic); |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
627 KeyedAccessStoreMode GetKeyedAccessStoreMode() const; | 625 KeyedAccessStoreMode GetKeyedAccessStoreMode() const; |
628 IcCheckType GetKeyType() const; | 626 IcCheckType GetKeyType() const; |
629 | 627 |
630 InlineCacheState StateFromFeedback() const override; | 628 InlineCacheState StateFromFeedback() const override; |
631 Name* FindFirstName() const override; | 629 Name* FindFirstName() const override; |
632 }; | 630 }; |
633 } // namespace internal | 631 } // namespace internal |
634 } // namespace v8 | 632 } // namespace v8 |
635 | 633 |
636 #endif // V8_TRANSITIONS_H_ | 634 #endif // V8_TRANSITIONS_H_ |
OLD | NEW |