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

Side by Side Diff: src/builtins/ia32/builtins-ia32.cc

Issue 2644643011: [builtins] Don't put doubles on the stack in ConstructWithSpread. (Closed)
Patch Set: Created 3 years, 11 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 unified diff | Download patch
« no previous file with comments | « src/builtins/arm64/builtins-arm64.cc ('k') | src/builtins/mips/builtins-mips.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_IA32 5 #if V8_TARGET_ARCH_IA32
6 6
7 #include "src/code-factory.h" 7 #include "src/code-factory.h"
8 #include "src/codegen.h" 8 #include "src/codegen.h"
9 #include "src/deoptimizer.h" 9 #include "src/deoptimizer.h"
10 #include "src/full-codegen/full-codegen.h" 10 #include "src/full-codegen/full-codegen.h"
(...skipping 2828 matching lines...) Expand 10 before | Expand all | Expand 10 after
2839 __ cmp(scratch, 2839 __ cmp(scratch,
2840 ContextOperand(scratch2, 2840 ContextOperand(scratch2,
2841 Context::INITIAL_ARRAY_ITERATOR_PROTOTYPE_MAP_INDEX)); 2841 Context::INITIAL_ARRAY_ITERATOR_PROTOTYPE_MAP_INDEX));
2842 __ j(not_equal, &runtime_call); 2842 __ j(not_equal, &runtime_call);
2843 2843
2844 // For FastPacked kinds, iteration will have the same effect as simply 2844 // For FastPacked kinds, iteration will have the same effect as simply
2845 // accessing each property in order. 2845 // accessing each property in order.
2846 Label no_protector_check; 2846 Label no_protector_check;
2847 __ mov(scratch, FieldOperand(spread_map, Map::kBitField2Offset)); 2847 __ mov(scratch, FieldOperand(spread_map, Map::kBitField2Offset));
2848 __ DecodeField<Map::ElementsKindBits>(scratch); 2848 __ DecodeField<Map::ElementsKindBits>(scratch);
2849 __ cmp(scratch, Immediate(LAST_FAST_ELEMENTS_KIND)); 2849 __ cmp(scratch, Immediate(FAST_HOLEY_ELEMENTS));
2850 __ j(above, &runtime_call); 2850 __ j(above, &runtime_call);
2851 // For non-FastHoley kinds, we can skip the protector check. 2851 // For non-FastHoley kinds, we can skip the protector check.
2852 __ cmp(scratch, Immediate(FAST_SMI_ELEMENTS)); 2852 __ cmp(scratch, Immediate(FAST_SMI_ELEMENTS));
2853 __ j(equal, &no_protector_check); 2853 __ j(equal, &no_protector_check);
2854 __ cmp(scratch, Immediate(FAST_ELEMENTS)); 2854 __ cmp(scratch, Immediate(FAST_ELEMENTS));
2855 __ j(equal, &no_protector_check); 2855 __ j(equal, &no_protector_check);
2856 __ cmp(scratch, Immediate(FAST_DOUBLE_ELEMENTS));
2857 __ j(equal, &no_protector_check);
2858 // Check the ArrayProtector cell. 2856 // Check the ArrayProtector cell.
2859 __ LoadRoot(scratch, Heap::kArrayProtectorRootIndex); 2857 __ LoadRoot(scratch, Heap::kArrayProtectorRootIndex);
2860 __ cmp(FieldOperand(scratch, PropertyCell::kValueOffset), 2858 __ cmp(FieldOperand(scratch, PropertyCell::kValueOffset),
2861 Immediate(Smi::FromInt(Isolate::kProtectorValid))); 2859 Immediate(Smi::FromInt(Isolate::kProtectorValid)));
2862 __ j(not_equal, &runtime_call); 2860 __ j(not_equal, &runtime_call);
2863 2861
2864 __ bind(&no_protector_check); 2862 __ bind(&no_protector_check);
2865 // Load the FixedArray backing store. 2863 // Load the FixedArray backing store.
2866 __ mov(spread, FieldOperand(spread, JSArray::kElementsOffset)); 2864 __ mov(spread, FieldOperand(spread, JSArray::kElementsOffset));
2867 // Free up some registers. 2865 // Free up some registers.
(...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after
3264 3262
3265 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) { 3263 void Builtins::Generate_InterpreterOnStackReplacement(MacroAssembler* masm) {
3266 Generate_OnStackReplacementHelper(masm, true); 3264 Generate_OnStackReplacementHelper(masm, true);
3267 } 3265 }
3268 3266
3269 #undef __ 3267 #undef __
3270 } // namespace internal 3268 } // namespace internal
3271 } // namespace v8 3269 } // namespace v8
3272 3270
3273 #endif // V8_TARGET_ARCH_IA32 3271 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/builtins/arm64/builtins-arm64.cc ('k') | src/builtins/mips/builtins-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698