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/interface-descriptors.h" | 7 #include "src/interface-descriptors.h" |
8 | 8 |
9 namespace v8 { | 9 namespace v8 { |
10 namespace internal { | 10 namespace internal { |
11 | 11 |
12 const Register CallInterfaceDescriptor::ContextRegister() { return esi; } | 12 const Register CallInterfaceDescriptor::ContextRegister() { return esi; } |
13 | 13 |
14 void CallInterfaceDescriptor::DefaultInitializePlatformSpecific( | 14 void CallInterfaceDescriptor::DefaultInitializePlatformSpecific( |
15 CallInterfaceDescriptorData* data, int register_parameter_count) { | 15 CallInterfaceDescriptorData* data, int register_parameter_count) { |
16 const Register default_stub_registers[] = {eax, ebx, ecx, edx, edi}; | 16 const Register default_stub_registers[] = {eax, ebx, ecx, edx, edi}; |
17 CHECK_LE(static_cast<size_t>(register_parameter_count), | 17 CHECK_LE(static_cast<size_t>(register_parameter_count), |
18 arraysize(default_stub_registers)); | 18 arraysize(default_stub_registers)); |
19 data->InitializePlatformSpecific(register_parameter_count, | 19 data->InitializePlatformSpecific(register_parameter_count, |
20 default_stub_registers); | 20 default_stub_registers); |
21 } | 21 } |
22 | 22 |
| 23 const Register FastNewFunctionContextDescriptor::FunctionRegister() { |
| 24 return edi; |
| 25 } |
| 26 const Register FastNewFunctionContextDescriptor::SlotsRegister() { return eax; } |
| 27 |
23 const Register LoadDescriptor::ReceiverRegister() { return edx; } | 28 const Register LoadDescriptor::ReceiverRegister() { return edx; } |
24 const Register LoadDescriptor::NameRegister() { return ecx; } | 29 const Register LoadDescriptor::NameRegister() { return ecx; } |
25 const Register LoadDescriptor::SlotRegister() { return eax; } | 30 const Register LoadDescriptor::SlotRegister() { return eax; } |
26 | 31 |
27 const Register LoadWithVectorDescriptor::VectorRegister() { return ebx; } | 32 const Register LoadWithVectorDescriptor::VectorRegister() { return ebx; } |
28 | 33 |
29 | 34 |
30 const Register StoreDescriptor::ReceiverRegister() { return edx; } | 35 const Register StoreDescriptor::ReceiverRegister() { return edx; } |
31 const Register StoreDescriptor::NameRegister() { return ecx; } | 36 const Register StoreDescriptor::NameRegister() { return ecx; } |
32 const Register StoreDescriptor::ValueRegister() { return eax; } | 37 const Register StoreDescriptor::ValueRegister() { return eax; } |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 const Register GrowArrayElementsDescriptor::ObjectRegister() { return eax; } | 74 const Register GrowArrayElementsDescriptor::ObjectRegister() { return eax; } |
70 const Register GrowArrayElementsDescriptor::KeyRegister() { return ebx; } | 75 const Register GrowArrayElementsDescriptor::KeyRegister() { return ebx; } |
71 | 76 |
72 | 77 |
73 void FastNewClosureDescriptor::InitializePlatformSpecific( | 78 void FastNewClosureDescriptor::InitializePlatformSpecific( |
74 CallInterfaceDescriptorData* data) { | 79 CallInterfaceDescriptorData* data) { |
75 Register registers[] = {ebx}; | 80 Register registers[] = {ebx}; |
76 data->InitializePlatformSpecific(arraysize(registers), registers, NULL); | 81 data->InitializePlatformSpecific(arraysize(registers), registers, NULL); |
77 } | 82 } |
78 | 83 |
79 void FastNewFunctionContextDescriptor::InitializePlatformSpecific( | |
80 CallInterfaceDescriptorData* data) { | |
81 Register registers[] = {edi}; | |
82 data->InitializePlatformSpecific(arraysize(registers), registers, NULL); | |
83 } | |
84 | |
85 void FastNewObjectDescriptor::InitializePlatformSpecific( | 84 void FastNewObjectDescriptor::InitializePlatformSpecific( |
86 CallInterfaceDescriptorData* data) { | 85 CallInterfaceDescriptorData* data) { |
87 Register registers[] = {edi, edx}; | 86 Register registers[] = {edi, edx}; |
88 data->InitializePlatformSpecific(arraysize(registers), registers); | 87 data->InitializePlatformSpecific(arraysize(registers), registers); |
89 } | 88 } |
90 | 89 |
91 void FastNewRestParameterDescriptor::InitializePlatformSpecific( | 90 void FastNewRestParameterDescriptor::InitializePlatformSpecific( |
92 CallInterfaceDescriptorData* data) { | 91 CallInterfaceDescriptorData* data) { |
93 Register registers[] = {edi}; | 92 Register registers[] = {edi}; |
94 data->InitializePlatformSpecific(arraysize(registers), registers, NULL); | 93 data->InitializePlatformSpecific(arraysize(registers), registers, NULL); |
(...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
412 ebx, // the JSGeneratorObject to resume | 411 ebx, // the JSGeneratorObject to resume |
413 edx // the resume mode (tagged) | 412 edx // the resume mode (tagged) |
414 }; | 413 }; |
415 data->InitializePlatformSpecific(arraysize(registers), registers); | 414 data->InitializePlatformSpecific(arraysize(registers), registers); |
416 } | 415 } |
417 | 416 |
418 } // namespace internal | 417 } // namespace internal |
419 } // namespace v8 | 418 } // namespace v8 |
420 | 419 |
421 #endif // V8_TARGET_ARCH_IA32 | 420 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |