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/interface-descriptors.h" | 7 #include "src/interface-descriptors.h" |
8 | 8 |
9 namespace v8 { | 9 namespace v8 { |
10 namespace internal { | 10 namespace internal { |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 CallInterfaceDescriptorData* data) { | 179 CallInterfaceDescriptorData* data) { |
180 Register registers[] = {rdi, rdx, rbx}; | 180 Register registers[] = {rdi, rdx, rbx}; |
181 data->InitializePlatformSpecific(arraysize(registers), registers); | 181 data->InitializePlatformSpecific(arraysize(registers), registers); |
182 } | 182 } |
183 | 183 |
184 | 184 |
185 void CallConstructDescriptor::InitializePlatformSpecific( | 185 void CallConstructDescriptor::InitializePlatformSpecific( |
186 CallInterfaceDescriptorData* data) { | 186 CallInterfaceDescriptorData* data) { |
187 // rax : number of arguments | 187 // rax : number of arguments |
188 // rbx : feedback vector | 188 // rbx : feedback vector |
189 // rcx : new target (for IsSuperConstructorCall) | |
190 // rdx : slot in feedback vector (Smi, for RecordCallTarget) | 189 // rdx : slot in feedback vector (Smi, for RecordCallTarget) |
191 // rdi : constructor function | 190 // rdi : constructor function |
192 // TODO(turbofan): So far we don't gather type feedback and hence skip the | 191 // TODO(turbofan): So far we don't gather type feedback and hence skip the |
193 // slot parameter, but ArrayConstructStub needs the vector to be undefined. | 192 // slot parameter, but ArrayConstructStub needs the vector to be undefined. |
194 Register registers[] = {rax, rdi, rcx, rbx}; | 193 Register registers[] = {rax, rdi, rbx}; |
195 data->InitializePlatformSpecific(arraysize(registers), registers); | 194 data->InitializePlatformSpecific(arraysize(registers), registers); |
196 } | 195 } |
197 | 196 |
198 | 197 |
199 void CallTrampolineDescriptor::InitializePlatformSpecific( | 198 void CallTrampolineDescriptor::InitializePlatformSpecific( |
200 CallInterfaceDescriptorData* data) { | 199 CallInterfaceDescriptorData* data) { |
201 // rax : number of arguments | 200 // rax : number of arguments |
202 // rdi : the target to call | 201 // rdi : the target to call |
203 Register registers[] = {rdi, rax}; | 202 Register registers[] = {rdi, rax}; |
204 data->InitializePlatformSpecific(arraysize(registers), registers); | 203 data->InitializePlatformSpecific(arraysize(registers), registers); |
205 } | 204 } |
206 | 205 |
207 | 206 |
| 207 void ConstructTrampolineDescriptor::InitializePlatformSpecific( |
| 208 CallInterfaceDescriptorData* data) { |
| 209 // rax : number of arguments |
| 210 // rdx : the new target |
| 211 // rdi : the target to call |
| 212 Register registers[] = {rdi, rdx, rax}; |
| 213 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 214 } |
| 215 |
| 216 |
208 void RegExpConstructResultDescriptor::InitializePlatformSpecific( | 217 void RegExpConstructResultDescriptor::InitializePlatformSpecific( |
209 CallInterfaceDescriptorData* data) { | 218 CallInterfaceDescriptorData* data) { |
210 Register registers[] = {rcx, rbx, rax}; | 219 Register registers[] = {rcx, rbx, rax}; |
211 data->InitializePlatformSpecific(arraysize(registers), registers); | 220 data->InitializePlatformSpecific(arraysize(registers), registers); |
212 } | 221 } |
213 | 222 |
214 | 223 |
215 void TransitionElementsKindDescriptor::InitializePlatformSpecific( | 224 void TransitionElementsKindDescriptor::InitializePlatformSpecific( |
216 CallInterfaceDescriptorData* data) { | 225 CallInterfaceDescriptorData* data) { |
217 Register registers[] = {rax, rbx}; | 226 Register registers[] = {rax, rbx}; |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
426 r15, // address of first argument (argv) | 435 r15, // address of first argument (argv) |
427 rbx // the runtime function to call | 436 rbx // the runtime function to call |
428 }; | 437 }; |
429 data->InitializePlatformSpecific(arraysize(registers), registers); | 438 data->InitializePlatformSpecific(arraysize(registers), registers); |
430 } | 439 } |
431 | 440 |
432 } // namespace internal | 441 } // namespace internal |
433 } // namespace v8 | 442 } // namespace v8 |
434 | 443 |
435 #endif // V8_TARGET_ARCH_X64 | 444 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |