| 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 { |
| 11 // Constructors for common combined semantic and representation types. | 11 // Constructors for common combined semantic and representation types. |
| 12 Type* SmiType() { | 12 Type* SmiType(Zone* zone) { |
| 13 return Type::Intersect(Type::SignedSmall(), Type::TaggedSigned()); | 13 return Type::Intersect(Type::SignedSmall(), Type::TaggedSigned(), zone); |
| 14 } | 14 } |
| 15 | 15 |
| 16 | 16 |
| 17 Type* UntaggedSigned32() { | 17 Type* UntaggedSigned32(Zone* zone) { |
| 18 return Type::Intersect(Type::Signed32(), Type::UntaggedSigned32()); | 18 return Type::Intersect(Type::Signed32(), Type::UntaggedSigned32(), zone); |
| 19 } | 19 } |
| 20 | 20 |
| 21 | 21 |
| 22 Type* AnyTagged() { | 22 Type* AnyTagged(Zone* zone) { |
| 23 return Type::Intersect( | 23 return Type::Intersect( |
| 24 Type::Any(), Type::Union(Type::TaggedPointer(), Type::TaggedSigned())); | 24 Type::Any(), |
| 25 Type::Union(Type::TaggedPointer(), Type::TaggedSigned(), zone), zone); |
| 25 } | 26 } |
| 26 | 27 |
| 27 | 28 |
| 28 Type* ExternalPointer() { | 29 Type* ExternalPointer(Zone* zone) { |
| 29 return Type::Intersect(Type::Internal(), Type::UntaggedPointer()); | 30 return Type::Intersect(Type::Internal(), Type::UntaggedPointer(), zone); |
| 30 } | 31 } |
| 31 } | 32 } |
| 32 | 33 |
| 33 | 34 |
| 34 Type::FunctionType* CallInterfaceDescriptor::BuildDefaultFunctionType( | 35 Type::FunctionType* CallInterfaceDescriptor::BuildDefaultFunctionType( |
| 35 Isolate* isolate, int parameter_count) { | 36 Isolate* isolate, int parameter_count) { |
| 36 Type::FunctionType* function = | 37 Zone* zone = isolate->interface_descriptor_zone(); |
| 37 Type::FunctionType::New(AnyTagged(), Type::Undefined(), parameter_count, | 38 Type::FunctionType* function = Type::FunctionType::New( |
| 38 isolate->interface_descriptor_zone()); | 39 AnyTagged(zone), Type::Undefined(), parameter_count, zone); |
| 39 while (parameter_count-- != 0) { | 40 while (parameter_count-- != 0) { |
| 40 function->InitParameter(parameter_count, AnyTagged()); | 41 function->InitParameter(parameter_count, AnyTagged(zone)); |
| 41 } | 42 } |
| 42 return function; | 43 return function; |
| 43 } | 44 } |
| 44 | 45 |
| 45 | 46 |
| 46 void CallInterfaceDescriptorData::InitializePlatformSpecific( | 47 void CallInterfaceDescriptorData::InitializePlatformSpecific( |
| 47 int register_parameter_count, Register* registers, | 48 int register_parameter_count, Register* registers, |
| 48 PlatformInterfaceDescriptor* platform_descriptor) { | 49 PlatformInterfaceDescriptor* platform_descriptor) { |
| 49 platform_specific_descriptor_ = platform_descriptor; | 50 platform_specific_descriptor_ = platform_descriptor; |
| 50 register_param_count_ = register_parameter_count; | 51 register_param_count_ = register_parameter_count; |
| (...skipping 18 matching lines...) Expand all Loading... |
| 69 #undef DEF_CASE | 70 #undef DEF_CASE |
| 70 case CallDescriptors::NUMBER_OF_DESCRIPTORS: | 71 case CallDescriptors::NUMBER_OF_DESCRIPTORS: |
| 71 break; | 72 break; |
| 72 } | 73 } |
| 73 return ""; | 74 return ""; |
| 74 } | 75 } |
| 75 | 76 |
| 76 | 77 |
| 77 Type::FunctionType* LoadDescriptor::BuildCallInterfaceDescriptorFunctionType( | 78 Type::FunctionType* LoadDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 78 Isolate* isolate, int paramater_count) { | 79 Isolate* isolate, int paramater_count) { |
| 79 Type::FunctionType* function = Type::FunctionType::New( | 80 Zone* zone = isolate->interface_descriptor_zone(); |
| 80 AnyTagged(), Type::Undefined(), 3, isolate->interface_descriptor_zone()); | 81 Type::FunctionType* function = |
| 81 function->InitParameter(0, AnyTagged()); | 82 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 3, zone); |
| 82 function->InitParameter(1, AnyTagged()); | 83 function->InitParameter(0, AnyTagged(zone)); |
| 83 function->InitParameter(2, SmiType()); | 84 function->InitParameter(1, AnyTagged(zone)); |
| 85 function->InitParameter(2, SmiType(zone)); |
| 84 return function; | 86 return function; |
| 85 } | 87 } |
| 86 | 88 |
| 87 void LoadDescriptor::InitializePlatformSpecific( | 89 void LoadDescriptor::InitializePlatformSpecific( |
| 88 CallInterfaceDescriptorData* data) { | 90 CallInterfaceDescriptorData* data) { |
| 89 Register registers[] = {ReceiverRegister(), NameRegister(), SlotRegister()}; | 91 Register registers[] = {ReceiverRegister(), NameRegister(), SlotRegister()}; |
| 90 data->InitializePlatformSpecific(arraysize(registers), registers); | 92 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 91 } | 93 } |
| 92 | 94 |
| 93 | 95 |
| 94 void StoreDescriptor::InitializePlatformSpecific( | 96 void StoreDescriptor::InitializePlatformSpecific( |
| 95 CallInterfaceDescriptorData* data) { | 97 CallInterfaceDescriptorData* data) { |
| 96 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister()}; | 98 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister()}; |
| 97 data->InitializePlatformSpecific(arraysize(registers), registers); | 99 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 98 } | 100 } |
| 99 | 101 |
| 100 | 102 |
| 101 void StoreTransitionDescriptor::InitializePlatformSpecific( | 103 void StoreTransitionDescriptor::InitializePlatformSpecific( |
| 102 CallInterfaceDescriptorData* data) { | 104 CallInterfaceDescriptorData* data) { |
| 103 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister(), | 105 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister(), |
| 104 MapRegister()}; | 106 MapRegister()}; |
| 105 | 107 |
| 106 data->InitializePlatformSpecific(arraysize(registers), registers); | 108 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 107 } | 109 } |
| 108 | 110 |
| 109 | 111 |
| 110 Type::FunctionType* | 112 Type::FunctionType* |
| 111 StoreTransitionDescriptor::BuildCallInterfaceDescriptorFunctionType( | 113 StoreTransitionDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 112 Isolate* isolate, int paramater_count) { | 114 Isolate* isolate, int paramater_count) { |
| 113 Type::FunctionType* function = Type::FunctionType::New( | 115 Zone* zone = isolate->interface_descriptor_zone(); |
| 114 AnyTagged(), Type::Undefined(), 4, isolate->interface_descriptor_zone()); | 116 Type::FunctionType* function = |
| 115 function->InitParameter(0, AnyTagged()); // Receiver | 117 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 4, zone); |
| 116 function->InitParameter(1, AnyTagged()); // Name | 118 function->InitParameter(0, AnyTagged(zone)); // Receiver |
| 117 function->InitParameter(2, AnyTagged()); // Value | 119 function->InitParameter(1, AnyTagged(zone)); // Name |
| 118 function->InitParameter(3, AnyTagged()); // Map | 120 function->InitParameter(2, AnyTagged(zone)); // Value |
| 121 function->InitParameter(3, AnyTagged(zone)); // Map |
| 119 return function; | 122 return function; |
| 120 } | 123 } |
| 121 | 124 |
| 122 | 125 |
| 123 Type::FunctionType* | 126 Type::FunctionType* |
| 124 LoadGlobalViaContextDescriptor::BuildCallInterfaceDescriptorFunctionType( | 127 LoadGlobalViaContextDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 125 Isolate* isolate, int paramater_count) { | 128 Isolate* isolate, int paramater_count) { |
| 126 Type::FunctionType* function = Type::FunctionType::New( | 129 Zone* zone = isolate->interface_descriptor_zone(); |
| 127 AnyTagged(), Type::Undefined(), 1, isolate->interface_descriptor_zone()); | 130 Type::FunctionType* function = |
| 128 function->InitParameter(0, UntaggedSigned32()); | 131 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 1, zone); |
| 132 function->InitParameter(0, UntaggedSigned32(zone)); |
| 129 return function; | 133 return function; |
| 130 } | 134 } |
| 131 | 135 |
| 132 | 136 |
| 133 void LoadGlobalViaContextDescriptor::InitializePlatformSpecific( | 137 void LoadGlobalViaContextDescriptor::InitializePlatformSpecific( |
| 134 CallInterfaceDescriptorData* data) { | 138 CallInterfaceDescriptorData* data) { |
| 135 Register registers[] = {SlotRegister()}; | 139 Register registers[] = {SlotRegister()}; |
| 136 data->InitializePlatformSpecific(arraysize(registers), registers); | 140 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 137 } | 141 } |
| 138 | 142 |
| 139 | 143 |
| 140 Type::FunctionType* | 144 Type::FunctionType* |
| 141 StoreGlobalViaContextDescriptor::BuildCallInterfaceDescriptorFunctionType( | 145 StoreGlobalViaContextDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 142 Isolate* isolate, int paramater_count) { | 146 Isolate* isolate, int paramater_count) { |
| 143 Type::FunctionType* function = Type::FunctionType::New( | 147 Zone* zone = isolate->interface_descriptor_zone(); |
| 144 AnyTagged(), Type::Undefined(), 2, isolate->interface_descriptor_zone()); | 148 Type::FunctionType* function = |
| 145 function->InitParameter(0, UntaggedSigned32()); | 149 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 2, zone); |
| 146 function->InitParameter(1, AnyTagged()); | 150 function->InitParameter(0, UntaggedSigned32(zone)); |
| 151 function->InitParameter(1, AnyTagged(zone)); |
| 147 return function; | 152 return function; |
| 148 } | 153 } |
| 149 | 154 |
| 150 | 155 |
| 151 void StoreGlobalViaContextDescriptor::InitializePlatformSpecific( | 156 void StoreGlobalViaContextDescriptor::InitializePlatformSpecific( |
| 152 CallInterfaceDescriptorData* data) { | 157 CallInterfaceDescriptorData* data) { |
| 153 Register registers[] = {SlotRegister(), ValueRegister()}; | 158 Register registers[] = {SlotRegister(), ValueRegister()}; |
| 154 data->InitializePlatformSpecific(arraysize(registers), registers); | 159 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 155 } | 160 } |
| 156 | 161 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 186 void MathPowIntegerDescriptor::InitializePlatformSpecific( | 191 void MathPowIntegerDescriptor::InitializePlatformSpecific( |
| 187 CallInterfaceDescriptorData* data) { | 192 CallInterfaceDescriptorData* data) { |
| 188 Register registers[] = {exponent()}; | 193 Register registers[] = {exponent()}; |
| 189 data->InitializePlatformSpecific(arraysize(registers), registers); | 194 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 190 } | 195 } |
| 191 | 196 |
| 192 | 197 |
| 193 Type::FunctionType* | 198 Type::FunctionType* |
| 194 LoadWithVectorDescriptor::BuildCallInterfaceDescriptorFunctionType( | 199 LoadWithVectorDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 195 Isolate* isolate, int paramater_count) { | 200 Isolate* isolate, int paramater_count) { |
| 196 Type::FunctionType* function = Type::FunctionType::New( | 201 Zone* zone = isolate->interface_descriptor_zone(); |
| 197 AnyTagged(), Type::Undefined(), 4, isolate->interface_descriptor_zone()); | 202 Type::FunctionType* function = |
| 198 function->InitParameter(0, AnyTagged()); | 203 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 4, zone); |
| 199 function->InitParameter(1, AnyTagged()); | 204 function->InitParameter(0, AnyTagged(zone)); |
| 200 function->InitParameter(2, SmiType()); | 205 function->InitParameter(1, AnyTagged(zone)); |
| 201 function->InitParameter(3, AnyTagged()); | 206 function->InitParameter(2, SmiType(zone)); |
| 207 function->InitParameter(3, AnyTagged(zone)); |
| 202 return function; | 208 return function; |
| 203 } | 209 } |
| 204 | 210 |
| 205 | 211 |
| 206 void LoadWithVectorDescriptor::InitializePlatformSpecific( | 212 void LoadWithVectorDescriptor::InitializePlatformSpecific( |
| 207 CallInterfaceDescriptorData* data) { | 213 CallInterfaceDescriptorData* data) { |
| 208 Register registers[] = {ReceiverRegister(), NameRegister(), SlotRegister(), | 214 Register registers[] = {ReceiverRegister(), NameRegister(), SlotRegister(), |
| 209 VectorRegister()}; | 215 VectorRegister()}; |
| 210 data->InitializePlatformSpecific(arraysize(registers), registers); | 216 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 211 } | 217 } |
| 212 | 218 |
| 213 | 219 |
| 214 Type::FunctionType* | 220 Type::FunctionType* |
| 215 VectorStoreTransitionDescriptor::BuildCallInterfaceDescriptorFunctionType( | 221 VectorStoreTransitionDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 216 Isolate* isolate, int paramater_count) { | 222 Isolate* isolate, int paramater_count) { |
| 217 Type::FunctionType* function = Type::FunctionType::New( | 223 Zone* zone = isolate->interface_descriptor_zone(); |
| 218 AnyTagged(), Type::Undefined(), 6, isolate->interface_descriptor_zone()); | 224 Type::FunctionType* function = |
| 219 function->InitParameter(0, AnyTagged()); // receiver | 225 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 6, zone); |
| 220 function->InitParameter(1, AnyTagged()); // name | 226 function->InitParameter(0, AnyTagged(zone)); // receiver |
| 221 function->InitParameter(2, AnyTagged()); // value | 227 function->InitParameter(1, AnyTagged(zone)); // name |
| 222 function->InitParameter(3, SmiType()); // slot | 228 function->InitParameter(2, AnyTagged(zone)); // value |
| 223 function->InitParameter(4, AnyTagged()); // vector | 229 function->InitParameter(3, SmiType(zone)); // slot |
| 224 function->InitParameter(5, AnyTagged()); // map | 230 function->InitParameter(4, AnyTagged(zone)); // vector |
| 231 function->InitParameter(5, AnyTagged(zone)); // map |
| 225 return function; | 232 return function; |
| 226 } | 233 } |
| 227 | 234 |
| 228 | 235 |
| 229 Type::FunctionType* | 236 Type::FunctionType* |
| 230 VectorStoreICDescriptor::BuildCallInterfaceDescriptorFunctionType( | 237 VectorStoreICDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 231 Isolate* isolate, int paramater_count) { | 238 Isolate* isolate, int paramater_count) { |
| 232 Type::FunctionType* function = Type::FunctionType::New( | 239 Zone* zone = isolate->interface_descriptor_zone(); |
| 233 AnyTagged(), Type::Undefined(), 5, isolate->interface_descriptor_zone()); | 240 Type::FunctionType* function = |
| 234 function->InitParameter(0, AnyTagged()); | 241 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 5, zone); |
| 235 function->InitParameter(1, AnyTagged()); | 242 function->InitParameter(0, AnyTagged(zone)); |
| 236 function->InitParameter(2, AnyTagged()); | 243 function->InitParameter(1, AnyTagged(zone)); |
| 237 function->InitParameter(3, SmiType()); | 244 function->InitParameter(2, AnyTagged(zone)); |
| 238 function->InitParameter(4, AnyTagged()); | 245 function->InitParameter(3, SmiType(zone)); |
| 246 function->InitParameter(4, AnyTagged(zone)); |
| 239 return function; | 247 return function; |
| 240 } | 248 } |
| 241 | 249 |
| 242 | 250 |
| 243 void VectorStoreICDescriptor::InitializePlatformSpecific( | 251 void VectorStoreICDescriptor::InitializePlatformSpecific( |
| 244 CallInterfaceDescriptorData* data) { | 252 CallInterfaceDescriptorData* data) { |
| 245 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister(), | 253 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister(), |
| 246 SlotRegister(), VectorRegister()}; | 254 SlotRegister(), VectorRegister()}; |
| 247 data->InitializePlatformSpecific(arraysize(registers), registers); | 255 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 248 } | 256 } |
| 249 | 257 |
| 250 | 258 |
| 251 Type::FunctionType* | 259 Type::FunctionType* |
| 252 VectorStoreICTrampolineDescriptor::BuildCallInterfaceDescriptorFunctionType( | 260 VectorStoreICTrampolineDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 253 Isolate* isolate, int paramater_count) { | 261 Isolate* isolate, int paramater_count) { |
| 254 Type::FunctionType* function = Type::FunctionType::New( | 262 Zone* zone = isolate->interface_descriptor_zone(); |
| 255 AnyTagged(), Type::Undefined(), 4, isolate->interface_descriptor_zone()); | 263 Type::FunctionType* function = |
| 256 function->InitParameter(0, AnyTagged()); | 264 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 4, zone); |
| 257 function->InitParameter(1, AnyTagged()); | 265 function->InitParameter(0, AnyTagged(zone)); |
| 258 function->InitParameter(2, AnyTagged()); | 266 function->InitParameter(1, AnyTagged(zone)); |
| 259 function->InitParameter(3, SmiType()); | 267 function->InitParameter(2, AnyTagged(zone)); |
| 268 function->InitParameter(3, SmiType(zone)); |
| 260 return function; | 269 return function; |
| 261 } | 270 } |
| 262 | 271 |
| 263 | 272 |
| 264 void VectorStoreICTrampolineDescriptor::InitializePlatformSpecific( | 273 void VectorStoreICTrampolineDescriptor::InitializePlatformSpecific( |
| 265 CallInterfaceDescriptorData* data) { | 274 CallInterfaceDescriptorData* data) { |
| 266 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister(), | 275 Register registers[] = {ReceiverRegister(), NameRegister(), ValueRegister(), |
| 267 SlotRegister()}; | 276 SlotRegister()}; |
| 268 data->InitializePlatformSpecific(arraysize(registers), registers); | 277 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 269 } | 278 } |
| 270 | 279 |
| 271 | 280 |
| 272 Type::FunctionType* | 281 Type::FunctionType* |
| 273 ApiGetterDescriptor::BuildCallInterfaceDescriptorFunctionType( | 282 ApiGetterDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 274 Isolate* isolate, int paramater_count) { | 283 Isolate* isolate, int paramater_count) { |
| 275 Type::FunctionType* function = Type::FunctionType::New( | 284 Zone* zone = isolate->interface_descriptor_zone(); |
| 276 AnyTagged(), Type::Undefined(), 1, isolate->interface_descriptor_zone()); | 285 Type::FunctionType* function = |
| 277 function->InitParameter(0, ExternalPointer()); | 286 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 1, zone); |
| 287 function->InitParameter(0, ExternalPointer(zone)); |
| 278 return function; | 288 return function; |
| 279 } | 289 } |
| 280 | 290 |
| 281 | 291 |
| 282 void ApiGetterDescriptor::InitializePlatformSpecific( | 292 void ApiGetterDescriptor::InitializePlatformSpecific( |
| 283 CallInterfaceDescriptorData* data) { | 293 CallInterfaceDescriptorData* data) { |
| 284 Register registers[] = {function_address()}; | 294 Register registers[] = {function_address()}; |
| 285 data->InitializePlatformSpecific(arraysize(registers), registers); | 295 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 286 } | 296 } |
| 287 | 297 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 302 void GrowArrayElementsDescriptor::InitializePlatformSpecific( | 312 void GrowArrayElementsDescriptor::InitializePlatformSpecific( |
| 303 CallInterfaceDescriptorData* data) { | 313 CallInterfaceDescriptorData* data) { |
| 304 Register registers[] = {ObjectRegister(), KeyRegister()}; | 314 Register registers[] = {ObjectRegister(), KeyRegister()}; |
| 305 data->InitializePlatformSpecific(arraysize(registers), registers); | 315 data->InitializePlatformSpecific(arraysize(registers), registers); |
| 306 } | 316 } |
| 307 | 317 |
| 308 | 318 |
| 309 Type::FunctionType* | 319 Type::FunctionType* |
| 310 FastCloneShallowArrayDescriptor::BuildCallInterfaceDescriptorFunctionType( | 320 FastCloneShallowArrayDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 311 Isolate* isolate, int paramater_count) { | 321 Isolate* isolate, int paramater_count) { |
| 312 Type::FunctionType* function = Type::FunctionType::New( | 322 Zone* zone = isolate->interface_descriptor_zone(); |
| 313 AnyTagged(), Type::Undefined(), 3, isolate->interface_descriptor_zone()); | 323 Type::FunctionType* function = |
| 314 function->InitParameter(0, AnyTagged()); | 324 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 3, zone); |
| 315 function->InitParameter(1, SmiType()); | 325 function->InitParameter(0, AnyTagged(zone)); |
| 316 function->InitParameter(2, AnyTagged()); | 326 function->InitParameter(1, SmiType(zone)); |
| 327 function->InitParameter(2, AnyTagged(zone)); |
| 317 return function; | 328 return function; |
| 318 } | 329 } |
| 319 | 330 |
| 320 | 331 |
| 321 Type::FunctionType* | 332 Type::FunctionType* |
| 322 CreateAllocationSiteDescriptor::BuildCallInterfaceDescriptorFunctionType( | 333 CreateAllocationSiteDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 323 Isolate* isolate, int paramater_count) { | 334 Isolate* isolate, int paramater_count) { |
| 324 Type::FunctionType* function = Type::FunctionType::New( | 335 Zone* zone = isolate->interface_descriptor_zone(); |
| 325 AnyTagged(), Type::Undefined(), 2, isolate->interface_descriptor_zone()); | 336 Type::FunctionType* function = |
| 326 function->InitParameter(0, AnyTagged()); | 337 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 2, zone); |
| 327 function->InitParameter(1, SmiType()); | 338 function->InitParameter(0, AnyTagged(zone)); |
| 339 function->InitParameter(1, SmiType(zone)); |
| 328 return function; | 340 return function; |
| 329 } | 341 } |
| 330 | 342 |
| 331 | 343 |
| 332 Type::FunctionType* | 344 Type::FunctionType* |
| 333 CreateWeakCellDescriptor::BuildCallInterfaceDescriptorFunctionType( | 345 CreateWeakCellDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 334 Isolate* isolate, int paramater_count) { | 346 Isolate* isolate, int paramater_count) { |
| 335 Type::FunctionType* function = Type::FunctionType::New( | 347 Zone* zone = isolate->interface_descriptor_zone(); |
| 336 AnyTagged(), Type::Undefined(), 3, isolate->interface_descriptor_zone()); | 348 Type::FunctionType* function = |
| 337 function->InitParameter(0, AnyTagged()); | 349 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 3, zone); |
| 338 function->InitParameter(1, SmiType()); | 350 function->InitParameter(0, AnyTagged(zone)); |
| 339 function->InitParameter(2, AnyTagged()); | 351 function->InitParameter(1, SmiType(zone)); |
| 352 function->InitParameter(2, AnyTagged(zone)); |
| 340 return function; | 353 return function; |
| 341 } | 354 } |
| 342 | 355 |
| 343 | 356 |
| 344 Type::FunctionType* | 357 Type::FunctionType* |
| 345 CallFunctionWithFeedbackDescriptor::BuildCallInterfaceDescriptorFunctionType( | 358 CallFunctionWithFeedbackDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 346 Isolate* isolate, int paramater_count) { | 359 Isolate* isolate, int paramater_count) { |
| 347 Type::FunctionType* function = Type::FunctionType::New( | 360 Zone* zone = isolate->interface_descriptor_zone(); |
| 348 AnyTagged(), Type::Undefined(), 2, isolate->interface_descriptor_zone()); | 361 Type::FunctionType* function = |
| 362 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 2, zone); |
| 349 function->InitParameter(0, Type::Receiver()); // JSFunction | 363 function->InitParameter(0, Type::Receiver()); // JSFunction |
| 350 function->InitParameter(1, SmiType()); | 364 function->InitParameter(1, SmiType(zone)); |
| 351 return function; | 365 return function; |
| 352 } | 366 } |
| 353 | 367 |
| 354 | 368 |
| 355 Type::FunctionType* CallFunctionWithFeedbackAndVectorDescriptor:: | 369 Type::FunctionType* CallFunctionWithFeedbackAndVectorDescriptor:: |
| 356 BuildCallInterfaceDescriptorFunctionType(Isolate* isolate, | 370 BuildCallInterfaceDescriptorFunctionType(Isolate* isolate, |
| 357 int paramater_count) { | 371 int paramater_count) { |
| 358 Type::FunctionType* function = Type::FunctionType::New( | 372 Zone* zone = isolate->interface_descriptor_zone(); |
| 359 AnyTagged(), Type::Undefined(), 3, isolate->interface_descriptor_zone()); | 373 Type::FunctionType* function = |
| 374 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 3, zone); |
| 360 function->InitParameter(0, Type::Receiver()); // JSFunction | 375 function->InitParameter(0, Type::Receiver()); // JSFunction |
| 361 function->InitParameter(1, SmiType()); | 376 function->InitParameter(1, SmiType(zone)); |
| 362 function->InitParameter(2, AnyTagged()); | 377 function->InitParameter(2, AnyTagged(zone)); |
| 363 return function; | 378 return function; |
| 364 } | 379 } |
| 365 | 380 |
| 366 | 381 |
| 367 Type::FunctionType* | 382 Type::FunctionType* |
| 368 ArrayConstructorDescriptor::BuildCallInterfaceDescriptorFunctionType( | 383 ArrayConstructorDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 369 Isolate* isolate, int paramater_count) { | 384 Isolate* isolate, int paramater_count) { |
| 370 Type::FunctionType* function = Type::FunctionType::New( | 385 Zone* zone = isolate->interface_descriptor_zone(); |
| 371 AnyTagged(), Type::Undefined(), 3, isolate->interface_descriptor_zone()); | 386 Type::FunctionType* function = |
| 387 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 3, zone); |
| 372 function->InitParameter(0, Type::Receiver()); // JSFunction | 388 function->InitParameter(0, Type::Receiver()); // JSFunction |
| 373 function->InitParameter(1, AnyTagged()); | 389 function->InitParameter(1, AnyTagged(zone)); |
| 374 function->InitParameter(2, UntaggedSigned32()); | 390 function->InitParameter(2, UntaggedSigned32(zone)); |
| 375 return function; | 391 return function; |
| 376 } | 392 } |
| 377 | 393 |
| 378 | 394 |
| 379 Type::FunctionType* | 395 Type::FunctionType* |
| 380 InternalArrayConstructorDescriptor::BuildCallInterfaceDescriptorFunctionType( | 396 InternalArrayConstructorDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 381 Isolate* isolate, int paramater_count) { | 397 Isolate* isolate, int paramater_count) { |
| 382 Type::FunctionType* function = Type::FunctionType::New( | 398 Zone* zone = isolate->interface_descriptor_zone(); |
| 383 AnyTagged(), Type::Undefined(), 2, isolate->interface_descriptor_zone()); | 399 Type::FunctionType* function = |
| 400 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 2, zone); |
| 384 function->InitParameter(0, Type::Receiver()); // JSFunction | 401 function->InitParameter(0, Type::Receiver()); // JSFunction |
| 385 function->InitParameter(1, UntaggedSigned32()); | 402 function->InitParameter(1, UntaggedSigned32(zone)); |
| 386 return function; | 403 return function; |
| 387 } | 404 } |
| 388 | 405 |
| 389 | 406 |
| 390 Type::FunctionType* | 407 Type::FunctionType* |
| 391 ArgumentAdaptorDescriptor::BuildCallInterfaceDescriptorFunctionType( | 408 ArgumentAdaptorDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 392 Isolate* isolate, int paramater_count) { | 409 Isolate* isolate, int paramater_count) { |
| 393 Type::FunctionType* function = Type::FunctionType::New( | 410 Zone* zone = isolate->interface_descriptor_zone(); |
| 394 AnyTagged(), Type::Undefined(), 3, isolate->interface_descriptor_zone()); | 411 Type::FunctionType* function = |
| 412 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 3, zone); |
| 395 function->InitParameter(0, Type::Receiver()); // JSFunction | 413 function->InitParameter(0, Type::Receiver()); // JSFunction |
| 396 function->InitParameter(1, UntaggedSigned32()); // actual number of arguments | 414 function->InitParameter( |
| 397 function->InitParameter(2, | 415 1, UntaggedSigned32(zone)); // actual number of arguments |
| 398 UntaggedSigned32()); // expected number of arguments | 416 function->InitParameter( |
| 417 2, |
| 418 UntaggedSigned32(zone)); // expected number of arguments |
| 399 return function; | 419 return function; |
| 400 } | 420 } |
| 401 | 421 |
| 402 | 422 |
| 403 Type::FunctionType* | 423 Type::FunctionType* |
| 404 ApiFunctionDescriptor::BuildCallInterfaceDescriptorFunctionType( | 424 ApiFunctionDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 405 Isolate* isolate, int paramater_count) { | 425 Isolate* isolate, int paramater_count) { |
| 406 Type::FunctionType* function = Type::FunctionType::New( | 426 Zone* zone = isolate->interface_descriptor_zone(); |
| 407 AnyTagged(), Type::Undefined(), 5, isolate->interface_descriptor_zone()); | 427 Type::FunctionType* function = |
| 408 function->InitParameter(0, AnyTagged()); // callee | 428 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 5, zone); |
| 409 function->InitParameter(1, AnyTagged()); // call_data | 429 function->InitParameter(0, AnyTagged(zone)); // callee |
| 410 function->InitParameter(2, AnyTagged()); // holder | 430 function->InitParameter(1, AnyTagged(zone)); // call_data |
| 411 function->InitParameter(3, ExternalPointer()); // api_function_address | 431 function->InitParameter(2, AnyTagged(zone)); // holder |
| 412 function->InitParameter(4, UntaggedSigned32()); // actual number of arguments | 432 function->InitParameter(3, ExternalPointer(zone)); // api_function_address |
| 433 function->InitParameter( |
| 434 4, UntaggedSigned32(zone)); // actual number of arguments |
| 413 return function; | 435 return function; |
| 414 } | 436 } |
| 415 | 437 |
| 416 | 438 |
| 417 Type::FunctionType* | 439 Type::FunctionType* |
| 418 ApiAccessorDescriptor::BuildCallInterfaceDescriptorFunctionType( | 440 ApiAccessorDescriptor::BuildCallInterfaceDescriptorFunctionType( |
| 419 Isolate* isolate, int paramater_count) { | 441 Isolate* isolate, int paramater_count) { |
| 420 Type::FunctionType* function = Type::FunctionType::New( | 442 Zone* zone = isolate->interface_descriptor_zone(); |
| 421 AnyTagged(), Type::Undefined(), 4, isolate->interface_descriptor_zone()); | 443 Type::FunctionType* function = |
| 422 function->InitParameter(0, AnyTagged()); // callee | 444 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 4, zone); |
| 423 function->InitParameter(1, AnyTagged()); // call_data | 445 function->InitParameter(0, AnyTagged(zone)); // callee |
| 424 function->InitParameter(2, AnyTagged()); // holder | 446 function->InitParameter(1, AnyTagged(zone)); // call_data |
| 425 function->InitParameter(3, ExternalPointer()); // api_function_address | 447 function->InitParameter(2, AnyTagged(zone)); // holder |
| 448 function->InitParameter(3, ExternalPointer(zone)); // api_function_address |
| 426 return function; | 449 return function; |
| 427 } | 450 } |
| 428 | 451 |
| 429 | 452 |
| 430 Type::FunctionType* MathRoundVariantCallFromUnoptimizedCodeDescriptor:: | 453 Type::FunctionType* MathRoundVariantCallFromUnoptimizedCodeDescriptor:: |
| 431 BuildCallInterfaceDescriptorFunctionType(Isolate* isolate, | 454 BuildCallInterfaceDescriptorFunctionType(Isolate* isolate, |
| 432 int paramater_count) { | 455 int paramater_count) { |
| 433 Type::FunctionType* function = Type::FunctionType::New( | 456 Zone* zone = isolate->interface_descriptor_zone(); |
| 434 AnyTagged(), Type::Undefined(), 4, isolate->interface_descriptor_zone()); | 457 Type::FunctionType* function = |
| 458 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 4, zone); |
| 435 function->InitParameter(0, Type::Receiver()); | 459 function->InitParameter(0, Type::Receiver()); |
| 436 function->InitParameter(1, SmiType()); | 460 function->InitParameter(1, SmiType(zone)); |
| 437 function->InitParameter(2, AnyTagged()); | 461 function->InitParameter(2, AnyTagged(zone)); |
| 438 function->InitParameter(3, AnyTagged()); | 462 function->InitParameter(3, AnyTagged(zone)); |
| 439 return function; | 463 return function; |
| 440 } | 464 } |
| 441 | 465 |
| 442 | 466 |
| 443 Type::FunctionType* MathRoundVariantCallFromOptimizedCodeDescriptor:: | 467 Type::FunctionType* MathRoundVariantCallFromOptimizedCodeDescriptor:: |
| 444 BuildCallInterfaceDescriptorFunctionType(Isolate* isolate, | 468 BuildCallInterfaceDescriptorFunctionType(Isolate* isolate, |
| 445 int paramater_count) { | 469 int paramater_count) { |
| 446 Type::FunctionType* function = Type::FunctionType::New( | 470 Zone* zone = isolate->interface_descriptor_zone(); |
| 447 AnyTagged(), Type::Undefined(), 5, isolate->interface_descriptor_zone()); | 471 Type::FunctionType* function = |
| 472 Type::FunctionType::New(AnyTagged(zone), Type::Undefined(), 5, zone); |
| 448 function->InitParameter(0, Type::Receiver()); | 473 function->InitParameter(0, Type::Receiver()); |
| 449 function->InitParameter(1, SmiType()); | 474 function->InitParameter(1, SmiType(zone)); |
| 450 function->InitParameter(2, AnyTagged()); | 475 function->InitParameter(2, AnyTagged(zone)); |
| 451 function->InitParameter(3, AnyTagged()); | 476 function->InitParameter(3, AnyTagged(zone)); |
| 452 function->InitParameter(4, AnyTagged()); | 477 function->InitParameter(4, AnyTagged(zone)); |
| 453 return function; | 478 return function; |
| 454 } | 479 } |
| 455 } // namespace internal | 480 } // namespace internal |
| 456 } // namespace v8 | 481 } // namespace v8 |
| OLD | NEW |