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

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

Issue 2900703002: [es2015] Precompute the descriptive string for symbols. (Closed)
Patch Set: Address feedback. Created 3 years, 7 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/mips64/builtins-mips64.cc ('k') | src/factory.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 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_X64 5 #if V8_TARGET_ARCH_X64
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/counters.h" 9 #include "src/counters.h"
10 #include "src/deoptimizer.h" 10 #include "src/deoptimizer.h"
(...skipping 1969 matching lines...) Expand 10 before | Expand all | Expand 10 after
1980 { 1980 {
1981 FrameScope scope(masm, StackFrame::MANUAL); 1981 FrameScope scope(masm, StackFrame::MANUAL);
1982 __ EnterBuiltinFrame(rsi, rdi, r8); 1982 __ EnterBuiltinFrame(rsi, rdi, r8);
1983 __ Call(masm->isolate()->builtins()->ToString(), RelocInfo::CODE_TARGET); 1983 __ Call(masm->isolate()->builtins()->ToString(), RelocInfo::CODE_TARGET);
1984 __ LeaveBuiltinFrame(rsi, rdi, r8); 1984 __ LeaveBuiltinFrame(rsi, rdi, r8);
1985 } 1985 }
1986 __ jmp(&drop_frame_and_ret, Label::kNear); 1986 __ jmp(&drop_frame_and_ret, Label::kNear);
1987 1987
1988 // 3b. Convert symbol in rax to a string. 1988 // 3b. Convert symbol in rax to a string.
1989 __ bind(&symbol_descriptive_string); 1989 __ bind(&symbol_descriptive_string);
1990 { 1990 __ movp(rax, FieldOperand(rax, Symbol::kDescriptiveStringOffset));
1991 __ PopReturnAddressTo(rcx); 1991 // Fall through.
1992 __ SmiToInteger32(r8, r8);
1993 __ leap(rsp, Operand(rsp, r8, times_pointer_size, kPointerSize));
1994 __ Push(rax);
1995 __ PushReturnAddressFrom(rcx);
1996 __ TailCallRuntime(Runtime::kSymbolDescriptiveString);
1997 }
1998 1992
1999 __ bind(&drop_frame_and_ret); 1993 __ bind(&drop_frame_and_ret);
2000 { 1994 {
2001 // Drop all arguments including the receiver. 1995 // Drop all arguments including the receiver.
2002 __ PopReturnAddressTo(rcx); 1996 __ PopReturnAddressTo(rcx);
2003 __ SmiToInteger32(r8, r8); 1997 __ SmiToInteger32(r8, r8);
2004 __ leap(rsp, Operand(rsp, r8, times_pointer_size, kPointerSize)); 1998 __ leap(rsp, Operand(rsp, r8, times_pointer_size, kPointerSize));
2005 __ PushReturnAddressFrom(rcx); 1999 __ PushReturnAddressFrom(rcx);
2006 __ Ret(); 2000 __ Ret();
2007 } 2001 }
(...skipping 1227 matching lines...) Expand 10 before | Expand all | Expand 10 after
3235 // Now jump to the instructions of the returned code object. 3229 // Now jump to the instructions of the returned code object.
3236 __ jmp(r11); 3230 __ jmp(r11);
3237 } 3231 }
3238 3232
3239 #undef __ 3233 #undef __
3240 3234
3241 } // namespace internal 3235 } // namespace internal
3242 } // namespace v8 3236 } // namespace v8
3243 3237
3244 #endif // V8_TARGET_ARCH_X64 3238 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/builtins/mips64/builtins-mips64.cc ('k') | src/factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698