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_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
6 | 6 |
7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
8 #include "src/api-arguments.h" | 8 #include "src/api-arguments.h" |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/bootstrapper.h" | 10 #include "src/bootstrapper.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 void ArrayNArgumentsConstructorStub::Generate(MacroAssembler* masm) { | 27 void ArrayNArgumentsConstructorStub::Generate(MacroAssembler* masm) { |
28 __ pop(ecx); | 28 __ pop(ecx); |
29 __ mov(MemOperand(esp, eax, times_4, 0), edi); | 29 __ mov(MemOperand(esp, eax, times_4, 0), edi); |
30 __ push(edi); | 30 __ push(edi); |
31 __ push(ebx); | 31 __ push(ebx); |
32 __ push(ecx); | 32 __ push(ecx); |
33 __ add(eax, Immediate(3)); | 33 __ add(eax, Immediate(3)); |
34 __ TailCallRuntime(Runtime::kNewArray); | 34 __ TailCallRuntime(Runtime::kNewArray); |
35 } | 35 } |
36 | 36 |
37 void FastFunctionBindStub::InitializeDescriptor( | |
38 CodeStubDescriptor* descriptor) { | |
39 Address deopt_handler = Runtime::FunctionForId(Runtime::kFunctionBind)->entry; | |
40 descriptor->Initialize(eax, deopt_handler, -1, JS_FUNCTION_STUB_MODE); | |
41 } | |
42 | |
43 void HydrogenCodeStub::GenerateLightweightMiss(MacroAssembler* masm, | 37 void HydrogenCodeStub::GenerateLightweightMiss(MacroAssembler* masm, |
44 ExternalReference miss) { | 38 ExternalReference miss) { |
45 // Update the static counter each time a new code stub is generated. | 39 // Update the static counter each time a new code stub is generated. |
46 isolate()->counters()->code_stubs()->Increment(); | 40 isolate()->counters()->code_stubs()->Increment(); |
47 | 41 |
48 CallInterfaceDescriptor descriptor = GetCallInterfaceDescriptor(); | 42 CallInterfaceDescriptor descriptor = GetCallInterfaceDescriptor(); |
49 int param_count = descriptor.GetRegisterParameterCount(); | 43 int param_count = descriptor.GetRegisterParameterCount(); |
50 { | 44 { |
51 // Call the runtime system in a fresh internal frame. | 45 // Call the runtime system in a fresh internal frame. |
52 FrameScope scope(masm, StackFrame::INTERNAL); | 46 FrameScope scope(masm, StackFrame::INTERNAL); |
(...skipping 4371 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4424 kStackUnwindSpace, nullptr, return_value_operand, | 4418 kStackUnwindSpace, nullptr, return_value_operand, |
4425 NULL); | 4419 NULL); |
4426 } | 4420 } |
4427 | 4421 |
4428 #undef __ | 4422 #undef __ |
4429 | 4423 |
4430 } // namespace internal | 4424 } // namespace internal |
4431 } // namespace v8 | 4425 } // namespace v8 |
4432 | 4426 |
4433 #endif // V8_TARGET_ARCH_IA32 | 4427 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |