Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1156)

Unified Diff: src/transitions.h

Issue 10692026: Moving prototype transitions into the header of the transition array. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressing comments Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/profile-generator.cc ('k') | src/transitions.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/transitions.h
diff --git a/src/transitions.h b/src/transitions.h
index 5abdf99f8c3cdbf72bb5650f6691a5834ff06f39..76d8bd3d5acfe20bf4d3eb28468f4a35b3051c4e 100644
--- a/src/transitions.h
+++ b/src/transitions.h
@@ -46,22 +46,33 @@ namespace internal {
// [length() - kTransitionSize] Last transition
class TransitionArray: public FixedArray {
public:
- inline Map* elements_transition();
- inline void set_elements_transition(
- Map* value,
- WriteBarrierMode mode = UPDATE_WRITE_BARRIER);
- inline void ClearElementsTransition();
- inline bool HasElementsTransition();
// Accessors for fetching instance transition at transition number.
inline String* GetKey(int transition_number);
- inline Object** GetKeySlot(int transition_number);
inline void SetKey(int transition_number, String* value);
+ inline Object** GetKeySlot(int transition_number);
+
inline Object* GetValue(int transition_number);
- inline Object** GetValueSlot(int transition_number);
inline void SetValue(int transition_number, Object* value);
+ inline Object** GetValueSlot(int transition_number);
+
inline Map* GetTargetMap(int transition_number);
inline PropertyDetails GetTargetDetails(int transition_number);
+
+ inline Map* elements_transition();
+ inline void set_elements_transition(
+ Map* value,
+ WriteBarrierMode mode = UPDATE_WRITE_BARRIER);
inline Object** GetElementsSlot();
Michael Starzinger 2012/07/09 16:40:55 Let's name that GetElementsTransitionSlot() instea
+ inline bool HasElementsTransition();
+ inline void ClearElementsTransition();
+
+ inline FixedArray* GetPrototypeTransitions();
+ inline void SetPrototypeTransitions(
+ FixedArray* prototype_transitions,
+ WriteBarrierMode mode = UPDATE_WRITE_BARRIER);
+ inline Object** GetPrototypeTransitionsSlot();
+ inline bool HasPrototypeTransitions();
+ inline HeapObject* UncheckedPrototypeTransitions();
// Returns the number of transitions in the array.
int number_of_transitions() {
@@ -99,11 +110,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 +
+ kPointerSize;
+ static const int kFirstOffset = kPrototypeTransitionsOffset + kPointerSize;
// Layout of map transition.
static const int kTransitionKey = 0;
« no previous file with comments | « src/profile-generator.cc ('k') | src/transitions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698