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 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
336 Handle<TypeFeedbackVector> vector_handle() const { | 336 Handle<TypeFeedbackVector> vector_handle() const { |
337 DCHECK(vector_ == NULL); | 337 DCHECK(vector_ == NULL); |
338 return vector_handle_; | 338 return vector_handle_; |
339 } | 339 } |
340 TypeFeedbackVector* vector() const { | 340 TypeFeedbackVector* vector() const { |
341 return vector_handle_.is_null() ? vector_ : *vector_handle_; | 341 return vector_handle_.is_null() ? vector_ : *vector_handle_; |
342 } | 342 } |
343 FeedbackVectorSlot slot() const { return slot_; } | 343 FeedbackVectorSlot slot() const { return slot_; } |
344 | 344 |
345 InlineCacheState ic_state() const { return StateFromFeedback(); } | 345 InlineCacheState ic_state() const { return StateFromFeedback(); } |
| 346 bool IsUninitialized() const { return StateFromFeedback() == UNINITIALIZED; } |
346 Map* FindFirstMap() const { | 347 Map* FindFirstMap() const { |
347 MapHandleList maps; | 348 MapHandleList maps; |
348 ExtractMaps(&maps); | 349 ExtractMaps(&maps); |
349 if (maps.length() > 0) return *maps.at(0); | 350 if (maps.length() > 0) return *maps.at(0); |
350 return NULL; | 351 return NULL; |
351 } | 352 } |
352 | 353 |
353 // TODO(mvstanton): remove FindAllMaps, it didn't survive a code review. | 354 // TODO(mvstanton): remove FindAllMaps, it didn't survive a code review. |
354 void FindAllMaps(MapHandleList* maps) const { ExtractMaps(maps); } | 355 void FindAllMaps(MapHandleList* maps) const { ExtractMaps(maps); } |
355 | 356 |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
534 KeyedAccessStoreMode GetKeyedAccessStoreMode() const; | 535 KeyedAccessStoreMode GetKeyedAccessStoreMode() const; |
535 IcCheckType GetKeyType() const; | 536 IcCheckType GetKeyType() const; |
536 | 537 |
537 InlineCacheState StateFromFeedback() const override; | 538 InlineCacheState StateFromFeedback() const override; |
538 Name* FindFirstName() const override; | 539 Name* FindFirstName() const override; |
539 }; | 540 }; |
540 } // namespace internal | 541 } // namespace internal |
541 } // namespace v8 | 542 } // namespace v8 |
542 | 543 |
543 #endif // V8_TRANSITIONS_H_ | 544 #endif // V8_TRANSITIONS_H_ |
OLD | NEW |