| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef V8_CALL_INTERFACE_DESCRIPTOR_H_ | 5 #ifndef V8_CALL_INTERFACE_DESCRIPTOR_H_ |
| 6 #define V8_CALL_INTERFACE_DESCRIPTOR_H_ | 6 #define V8_CALL_INTERFACE_DESCRIPTOR_H_ |
| 7 | 7 |
| 8 #include "src/assembler.h" | 8 #include "src/assembler.h" |
| 9 #include "src/macro-assembler.h" | 9 #include "src/macro-assembler.h" |
| 10 | 10 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 V(Keyed) \ | 46 V(Keyed) \ |
| 47 V(Named) \ | 47 V(Named) \ |
| 48 V(CallHandler) \ | 48 V(CallHandler) \ |
| 49 V(ArgumentAdaptor) \ | 49 V(ArgumentAdaptor) \ |
| 50 V(ApiGetter) \ | 50 V(ApiGetter) \ |
| 51 V(ApiFunction) \ | 51 V(ApiFunction) \ |
| 52 V(ArgumentsAccessRead) \ | 52 V(ArgumentsAccessRead) \ |
| 53 V(StoreArrayLiteralElement) \ | 53 V(StoreArrayLiteralElement) \ |
| 54 V(MathPowTagged) \ | 54 V(MathPowTagged) \ |
| 55 V(MathPowInteger) \ | 55 V(MathPowInteger) \ |
| 56 V(ContextOnly) | 56 V(ContextOnly) \ |
| 57 V(GrowArrayElements) |
| 57 | 58 |
| 58 | 59 |
| 59 class CallInterfaceDescriptorData { | 60 class CallInterfaceDescriptorData { |
| 60 public: | 61 public: |
| 61 CallInterfaceDescriptorData() : register_param_count_(-1) {} | 62 CallInterfaceDescriptorData() : register_param_count_(-1) {} |
| 62 | 63 |
| 63 // A copy of the passed in registers and param_representations is made | 64 // A copy of the passed in registers and param_representations is made |
| 64 // and owned by the CallInterfaceDescriptorData. | 65 // and owned by the CallInterfaceDescriptorData. |
| 65 | 66 |
| 66 // TODO(mvstanton): Instead of taking parallel arrays register and | 67 // TODO(mvstanton): Instead of taking parallel arrays register and |
| (...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 481 | 482 |
| 482 static const Register exponent(); | 483 static const Register exponent(); |
| 483 }; | 484 }; |
| 484 | 485 |
| 485 | 486 |
| 486 class ContextOnlyDescriptor : public CallInterfaceDescriptor { | 487 class ContextOnlyDescriptor : public CallInterfaceDescriptor { |
| 487 public: | 488 public: |
| 488 DECLARE_DESCRIPTOR(ContextOnlyDescriptor, CallInterfaceDescriptor) | 489 DECLARE_DESCRIPTOR(ContextOnlyDescriptor, CallInterfaceDescriptor) |
| 489 }; | 490 }; |
| 490 | 491 |
| 492 |
| 493 class GrowArrayElementsDescriptor : public CallInterfaceDescriptor { |
| 494 public: |
| 495 DECLARE_DESCRIPTOR(GrowArrayElementsDescriptor, CallInterfaceDescriptor) |
| 496 |
| 497 enum RegisterInfo { kObjectIndex, kKeyIndex, kCapacityIndex }; |
| 498 static const Register ObjectRegister(); |
| 499 static const Register KeyRegister(); |
| 500 static const Register CapacityRegister(); |
| 501 }; |
| 502 |
| 491 #undef DECLARE_DESCRIPTOR | 503 #undef DECLARE_DESCRIPTOR |
| 492 | 504 |
| 493 | 505 |
| 494 // We define the association between CallDescriptors::Key and the specialized | 506 // We define the association between CallDescriptors::Key and the specialized |
| 495 // descriptor here to reduce boilerplate and mistakes. | 507 // descriptor here to reduce boilerplate and mistakes. |
| 496 #define DEF_KEY(name) \ | 508 #define DEF_KEY(name) \ |
| 497 CallDescriptors::Key name##Descriptor::key() { return CallDescriptors::name; } | 509 CallDescriptors::Key name##Descriptor::key() { return CallDescriptors::name; } |
| 498 INTERFACE_DESCRIPTOR_LIST(DEF_KEY) | 510 INTERFACE_DESCRIPTOR_LIST(DEF_KEY) |
| 499 #undef DEF_KEY | 511 #undef DEF_KEY |
| 500 } | 512 } |
| 501 } // namespace v8::internal | 513 } // namespace v8::internal |
| 502 | 514 |
| 503 | 515 |
| 504 #if V8_TARGET_ARCH_ARM64 | 516 #if V8_TARGET_ARCH_ARM64 |
| 505 #include "src/arm64/interface-descriptors-arm64.h" | 517 #include "src/arm64/interface-descriptors-arm64.h" |
| 506 #elif V8_TARGET_ARCH_ARM | 518 #elif V8_TARGET_ARCH_ARM |
| 507 #include "src/arm/interface-descriptors-arm.h" | 519 #include "src/arm/interface-descriptors-arm.h" |
| 508 #endif | 520 #endif |
| 509 | 521 |
| 510 #endif // V8_CALL_INTERFACE_DESCRIPTOR_H_ | 522 #endif // V8_CALL_INTERFACE_DESCRIPTOR_H_ |
| OLD | NEW |