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

Unified Diff: src/ia32/stub-cache-ia32.cc

Issue 8177005: Active smi-only optimizations for large array literals. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: review feedback Created 9 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/ia32/ic-ia32.cc ('k') | src/objects.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ia32/stub-cache-ia32.cc
diff --git a/src/ia32/stub-cache-ia32.cc b/src/ia32/stub-cache-ia32.cc
index 9b8f096621b5b2710f5c4f18c726e1ba0f139df4..53f9d5bd031469649453754192b39f1b7bace419 100644
--- a/src/ia32/stub-cache-ia32.cc
+++ b/src/ia32/stub-cache-ia32.cc
@@ -1486,10 +1486,8 @@ MaybeObject* CallStubCompiler::CompileArrayPushCall(Object* object,
__ bind(&with_write_barrier);
- if (FLAG_smi_only_arrays) {
- __ mov(edi, FieldOperand(edx, HeapObject::kMapOffset));
- __ CheckFastObjectElements(edi, &call_builtin);
- }
+ __ mov(edi, FieldOperand(edx, HeapObject::kMapOffset));
+ __ CheckFastObjectElements(edi, &call_builtin);
// Save new length.
__ mov(FieldOperand(edx, JSArray::kLengthOffset), eax);
@@ -1511,15 +1509,13 @@ MaybeObject* CallStubCompiler::CompileArrayPushCall(Object* object,
}
__ mov(edi, Operand(esp, argc * kPointerSize));
- if (FLAG_smi_only_arrays) {
- // Growing elements that are SMI-only requires special handling in case
- // the new element is non-Smi. For now, delegate to the builtin.
- Label no_fast_elements_check;
- __ JumpIfSmi(edi, &no_fast_elements_check);
- __ mov(esi, FieldOperand(edx, HeapObject::kMapOffset));
- __ CheckFastObjectElements(esi, &call_builtin, Label::kFar);
- __ bind(&no_fast_elements_check);
- }
+ // Growing elements that are SMI-only requires special handling in case
+ // the new element is non-Smi. For now, delegate to the builtin.
+ Label no_fast_elements_check;
+ __ JumpIfSmi(edi, &no_fast_elements_check);
+ __ mov(esi, FieldOperand(edx, HeapObject::kMapOffset));
+ __ CheckFastObjectElements(esi, &call_builtin, Label::kFar);
+ __ bind(&no_fast_elements_check);
// We could be lucky and the elements array could be at the top of
// new-space. In this case we can just grow it in place by moving the
« no previous file with comments | « src/ia32/ic-ia32.cc ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698