Chromium Code Reviews| Index: src/transitions.h |
| diff --git a/src/transitions.h b/src/transitions.h |
| index 5abdf99f8c3cdbf72bb5650f6691a5834ff06f39..ba7b4dfbf7233c5441f333470dc85a1af68fe665 100644 |
| --- a/src/transitions.h |
| +++ b/src/transitions.h |
| @@ -52,6 +52,12 @@ class TransitionArray: public FixedArray { |
| WriteBarrierMode mode = UPDATE_WRITE_BARRIER); |
| inline void ClearElementsTransition(); |
| inline bool HasElementsTransition(); |
| + inline FixedArray* prototype_transitions(); |
| + inline void set_prototype_transitions( |
| + FixedArray* prototype_transitions, |
| + WriteBarrierMode mode = UPDATE_WRITE_BARRIER); |
| + inline HeapObject* unchecked_prototype_transitions(); |
| + inline bool HasPrototypeTransitions(); |
| // Accessors for fetching instance transition at transition number. |
| inline String* GetKey(int transition_number); |
| inline Object** GetKeySlot(int transition_number); |
| @@ -62,6 +68,8 @@ class TransitionArray: public FixedArray { |
| inline Map* GetTargetMap(int transition_number); |
| inline PropertyDetails GetTargetDetails(int transition_number); |
| inline Object** GetElementsSlot(); |
| + inline Object** GetPrototypeTransitionsSlot(); |
|
Michael Starzinger
2012/07/06 13:53:18
Can we group these accessors somehow, this is beco
Toon Verwaest
2012/07/09 12:45:27
Done.
|
| + bool TransitionsTo(Object* target); |
| // Returns the number of transitions in the array. |
| int number_of_transitions() { |
| @@ -99,11 +107,14 @@ class TransitionArray: public FixedArray { |
| static const int kNotFound = -1; |
| static const int kElementsTransitionIndex = 0; |
| - static const int kFirstIndex = 1; |
| + static const int kPrototypeTransitionsIndex = 1; |
| + static const int kFirstIndex = 2; |
| // Layout transition array header. |
| static const int kElementsTransitionOffset = FixedArray::kHeaderSize; |
| - static const int kFirstOffset = kElementsTransitionOffset + kPointerSize; |
| + static const int kPrototypeTransitionsOffset = kElementsTransitionOffset + |
|
Michael Starzinger
2012/07/06 13:53:18
Better break that after the "=", to be consistent
|
| + kPointerSize; |
| + static const int kFirstOffset = kPrototypeTransitionsOffset + kPointerSize; |
| // Layout of map transition. |
| static const int kTransitionKey = 0; |