OLD | NEW |
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 Loading... |
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 Loading... |
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 |
OLD | NEW |