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

Unified Diff: src/objects-inl.h

Issue 635883003: Limit the number of transitions allowed per hidden class. (Closed) Base URL: https://chromium.googlesource.com/external/v8.git@bleeding_edge
Patch Set: Added growth; changed limit Created 6 years, 2 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/objects.cc ('k') | src/transitions.h » ('j') | src/transitions.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects-inl.h
diff --git a/src/objects-inl.h b/src/objects-inl.h
index 4e964f82310d48567a97577df574cd43db4204eb..2ce4e71fe01db3be15bd3e9093a1b21102084ba9 100644
--- a/src/objects-inl.h
+++ b/src/objects-inl.h
@@ -5208,9 +5208,8 @@ Map* Map::elements_transition_map() {
bool Map::CanHaveMoreTransitions() {
if (!HasTransitionArray()) return true;
- return FixedArray::SizeFor(transitions()->length() +
- TransitionArray::kTransitionSize)
- <= Page::kMaxRegularHeapObjectSize;
+ return transitions()->number_of_transitions() <=
+ TransitionArray::kMaxNumberOfTransitions;
}
« no previous file with comments | « src/objects.cc ('k') | src/transitions.h » ('j') | src/transitions.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698