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

Unified Diff: src/transitions.cc

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
Index: src/transitions.cc
diff --git a/src/transitions.cc b/src/transitions.cc
index 033f224c173e2de3397461f286ef7c972e5127e5..1e965cda716af594d198ab118a01a72bd4a78da8 100644
--- a/src/transitions.cc
+++ b/src/transitions.cc
@@ -45,6 +45,7 @@ MaybeObject* TransitionArray::Allocate(int number_of_transitions) {
}
array->set(kElementsTransitionIndex, Smi::FromInt(0));
+ array->set(kPrototypeTransitionsIndex, Smi::FromInt(0));
return array;
}
@@ -98,6 +99,10 @@ MaybeObject* TransitionArray::CopyInsert(String* name, Object* value) {
result->set_elements_transition(elements_transition());
}
+ if (HasPrototypeTransitions()) {
+ result->SetPrototypeTransitions(GetPrototypeTransitions());
+ }
+
FixedArray::WhitenessWitness witness(result);
if (insertion_index != kNotFound) {
« src/transitions.h ('K') | « src/transitions.h ('k') | src/transitions-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698