| 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 #include "src/interface-descriptors.h" | 5 #include "src/interface-descriptors.h" |
| 6 | 6 |
| 7 namespace v8 { | 7 namespace v8 { |
| 8 namespace internal { | 8 namespace internal { |
| 9 | 9 |
| 10 namespace { | 10 namespace { |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 void LoadDescriptor::InitializePlatformSpecific( | 94 void LoadDescriptor::InitializePlatformSpecific( |
| 95 CallInterfaceDescriptorData* data) { | 95 CallInterfaceDescriptorData* data) { |
| 96 Register registers[] = {ReceiverRegister(), NameRegister(), SlotRegister()}; | 96 Register registers[] = {ReceiverRegister(), NameRegister(), SlotRegister()}; |
| 97 data->InitializePlatformSpecific(arraysize(registers), registers); | 97 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 98 } | 98 } |
| 99 | 99 |
| 100 FunctionType* LoadGlobalDescriptor::BuildCallInterfaceDescriptorFunctionType( | 100 FunctionType* LoadGlobalDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 101 Isolate* isolate, int paramater_count) { | 101 Isolate* isolate, int paramater_count) { |
| 102 Zone* zone = isolate->interface_descriptor_zone(); | 102 Zone* zone = isolate->interface_descriptor_zone(); |
| 103 FunctionType* function = | 103 FunctionType* function = |
| 104 Type::Function(AnyTagged(zone), Type::Undefined(), 2, zone)->AsFunction(); | 104 Type::Function(AnyTagged(zone), Type::Undefined(), 1, zone)->AsFunction(); |
| 105 function->InitParameter(0, AnyTagged(zone)); | 105 function->InitParameter(0, SmiType(zone)); |
| 106 function->InitParameter(1, SmiType(zone)); | |
| 107 return function; | 106 return function; |
| 108 } | 107 } |
| 109 | 108 |
| 110 void LoadGlobalDescriptor::InitializePlatformSpecific( | 109 void LoadGlobalDescriptor::InitializePlatformSpecific( |
| 111 CallInterfaceDescriptorData* data) { | 110 CallInterfaceDescriptorData* data) { |
| 112 Register registers[] = {LoadWithVectorDescriptor::NameRegister(), | 111 Register registers[] = {LoadWithVectorDescriptor::SlotRegister()}; |
| 113 LoadWithVectorDescriptor::SlotRegister()}; | |
| 114 data->InitializePlatformSpecific(arraysize(registers), registers); | 112 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 115 } | 113 } |
| 116 | 114 |
| 117 FunctionType* | 115 FunctionType* |
| 118 LoadGlobalWithVectorDescriptor::BuildCallInterfaceDescriptorFunctionType( | 116 LoadGlobalWithVectorDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 119 Isolate* isolate, int paramater_count) { | 117 Isolate* isolate, int paramater_count) { |
| 120 Zone* zone = isolate->interface_descriptor_zone(); | 118 Zone* zone = isolate->interface_descriptor_zone(); |
| 121 FunctionType* function = | 119 FunctionType* function = |
| 122 Type::Function(AnyTagged(zone), Type::Undefined(), 3, zone)->AsFunction(); | 120 Type::Function(AnyTagged(zone), Type::Undefined(), 2, zone)->AsFunction(); |
| 123 function->InitParameter(0, AnyTagged(zone)); | 121 function->InitParameter(0, SmiType(zone)); |
| 124 function->InitParameter(1, SmiType(zone)); | 122 function->InitParameter(1, AnyTagged(zone)); |
| 125 function->InitParameter(2, AnyTagged(zone)); | |
| 126 return function; | 123 return function; |
| 127 } | 124 } |
| 128 | 125 |
| 129 void LoadGlobalWithVectorDescriptor::InitializePlatformSpecific( | 126 void LoadGlobalWithVectorDescriptor::InitializePlatformSpecific( |
| 130 CallInterfaceDescriptorData* data) { | 127 CallInterfaceDescriptorData* data) { |
| 131 Register registers[] = {LoadWithVectorDescriptor::NameRegister(), | 128 Register registers[] = {LoadWithVectorDescriptor::SlotRegister(), |
| 132 LoadWithVectorDescriptor::SlotRegister(), | |
| 133 LoadWithVectorDescriptor::VectorRegister()}; | 129 LoadWithVectorDescriptor::VectorRegister()}; |
| 134 data->InitializePlatformSpecific(arraysize(registers), registers); | 130 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 135 } | 131 } |
| 136 | 132 |
| 137 void StoreDescriptor::InitializePlatformSpecific( | 133 void StoreDescriptor::InitializePlatformSpecific( |
| 138 CallInterfaceDescriptorData* data) { | 134 CallInterfaceDescriptorData* data) { |
| 139 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister()}; | 135 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister()}; |
| 140 data->InitializePlatformSpecific(arraysize(registers), registers); | 136 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 141 } | 137 } |
| 142 | 138 |
| (...skipping 444 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 587 Type::Function(AnyTagged(zone), Type::Undefined(), 4, zone)->AsFunction(); | 583 Type::Function(AnyTagged(zone), Type::Undefined(), 4, zone)->AsFunction(); |
| 588 function->InitParameter(kAccumulatorParameter, AnyTagged(zone)); | 584 function->InitParameter(kAccumulatorParameter, AnyTagged(zone)); |
| 589 function->InitParameter(kBytecodeOffsetParameter, UntaggedIntegral32(zone)); | 585 function->InitParameter(kBytecodeOffsetParameter, UntaggedIntegral32(zone)); |
| 590 function->InitParameter(kBytecodeArrayParameter, AnyTagged(zone)); | 586 function->InitParameter(kBytecodeArrayParameter, AnyTagged(zone)); |
| 591 function->InitParameter(kDispatchTableParameter, AnyTagged(zone)); | 587 function->InitParameter(kDispatchTableParameter, AnyTagged(zone)); |
| 592 return function; | 588 return function; |
| 593 } | 589 } |
| 594 | 590 |
| 595 } // namespace internal | 591 } // namespace internal |
| 596 } // namespace v8 | 592 } // namespace v8 |
| OLD | NEW |