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

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

Issue 2327703003: [builtins] Migrate ToNumber to TurboFan. (Closed)
Patch Set: Rebase Created 4 years, 3 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/arm/builtins-arm.cc ('k') | src/builtins/builtins.h » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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_ARM64 5 #if V8_TARGET_ARCH_ARM64
6 6
7 #include "src/arm64/frames-arm64.h" 7 #include "src/arm64/frames-arm64.h"
8 #include "src/codegen.h" 8 #include "src/codegen.h"
9 #include "src/debug/debug.h" 9 #include "src/debug/debug.h"
10 #include "src/deoptimizer.h" 10 #include "src/deoptimizer.h"
(...skipping 2898 matching lines...) Expand 10 before | Expand all | Expand 10 after
2909 // ----------- S t a t e ------------- 2909 // ----------- S t a t e -------------
2910 // -- x1 : message_id as Smi 2910 // -- x1 : message_id as Smi
2911 // -- lr : return address 2911 // -- lr : return address
2912 // ----------------------------------- 2912 // -----------------------------------
2913 MacroAssembler::NoUseRealAbortsScope no_use_real_aborts(masm); 2913 MacroAssembler::NoUseRealAbortsScope no_use_real_aborts(masm);
2914 __ Push(x1); 2914 __ Push(x1);
2915 __ Move(cp, Smi::FromInt(0)); 2915 __ Move(cp, Smi::FromInt(0));
2916 __ TailCallRuntime(Runtime::kAbort); 2916 __ TailCallRuntime(Runtime::kAbort);
2917 } 2917 }
2918 2918
2919 // static
2920 void Builtins::Generate_ToNumber(MacroAssembler* masm) {
2921 // The ToNumber stub takes one argument in x0.
2922 Label not_smi;
2923 __ JumpIfNotSmi(x0, &not_smi);
2924 __ Ret();
2925 __ Bind(&not_smi);
2926
2927 Label not_heap_number;
2928 __ CompareObjectType(x0, x1, x1, HEAP_NUMBER_TYPE);
2929 // x0: receiver
2930 // x1: receiver instance type
2931 __ B(ne, &not_heap_number);
2932 __ Ret();
2933 __ Bind(&not_heap_number);
2934
2935 __ Jump(masm->isolate()->builtins()->NonNumberToNumber(),
2936 RelocInfo::CODE_TARGET);
2937 }
2938
2939 void Builtins::Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm) { 2919 void Builtins::Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm) {
2940 ASM_LOCATION("Builtins::Generate_ArgumentsAdaptorTrampoline"); 2920 ASM_LOCATION("Builtins::Generate_ArgumentsAdaptorTrampoline");
2941 // ----------- S t a t e ------------- 2921 // ----------- S t a t e -------------
2942 // -- x0 : actual number of arguments 2922 // -- x0 : actual number of arguments
2943 // -- x1 : function (passed through to callee) 2923 // -- x1 : function (passed through to callee)
2944 // -- x2 : expected number of arguments 2924 // -- x2 : expected number of arguments
2945 // -- x3 : new target (passed through to callee) 2925 // -- x3 : new target (passed through to callee)
2946 // ----------------------------------- 2926 // -----------------------------------
2947 2927
2948 Register argc_actual = x0; // Excluding the receiver. 2928 Register argc_actual = x0; // Excluding the receiver.
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
3080 __ Unreachable(); 3060 __ Unreachable();
3081 } 3061 }
3082 } 3062 }
3083 3063
3084 #undef __ 3064 #undef __
3085 3065
3086 } // namespace internal 3066 } // namespace internal
3087 } // namespace v8 3067 } // namespace v8
3088 3068
3089 #endif // V8_TARGET_ARCH_ARM 3069 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/builtins/arm/builtins-arm.cc ('k') | src/builtins/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698