OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_CRANKSHAFT_ARM64_LITHIUM_ARM64_H_ | 5 #ifndef V8_CRANKSHAFT_ARM64_LITHIUM_ARM64_H_ |
6 #define V8_CRANKSHAFT_ARM64_LITHIUM_ARM64_H_ | 6 #define V8_CRANKSHAFT_ARM64_LITHIUM_ARM64_H_ |
7 | 7 |
8 #include "src/crankshaft/hydrogen.h" | 8 #include "src/crankshaft/hydrogen.h" |
9 #include "src/crankshaft/lithium.h" | 9 #include "src/crankshaft/lithium.h" |
10 #include "src/crankshaft/lithium-allocator.h" | 10 #include "src/crankshaft/lithium-allocator.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 V(DeclareGlobals) \ | 63 V(DeclareGlobals) \ |
64 V(Deoptimize) \ | 64 V(Deoptimize) \ |
65 V(DivByConstI) \ | 65 V(DivByConstI) \ |
66 V(DivByPowerOf2I) \ | 66 V(DivByPowerOf2I) \ |
67 V(DivI) \ | 67 V(DivI) \ |
68 V(DoubleBits) \ | 68 V(DoubleBits) \ |
69 V(DoubleToIntOrSmi) \ | 69 V(DoubleToIntOrSmi) \ |
70 V(Drop) \ | 70 V(Drop) \ |
71 V(Dummy) \ | 71 V(Dummy) \ |
72 V(DummyUse) \ | 72 V(DummyUse) \ |
| 73 V(FastAllocate) \ |
73 V(FlooringDivByConstI) \ | 74 V(FlooringDivByConstI) \ |
74 V(FlooringDivByPowerOf2I) \ | 75 V(FlooringDivByPowerOf2I) \ |
75 V(FlooringDivI) \ | 76 V(FlooringDivI) \ |
76 V(ForInCacheArray) \ | 77 V(ForInCacheArray) \ |
77 V(ForInPrepareMap) \ | 78 V(ForInPrepareMap) \ |
78 V(GetCachedArrayIndex) \ | 79 V(GetCachedArrayIndex) \ |
79 V(Goto) \ | 80 V(Goto) \ |
80 V(HasCachedArrayIndexAndBranch) \ | 81 V(HasCachedArrayIndexAndBranch) \ |
81 V(HasInPrototypeChainAndBranch) \ | 82 V(HasInPrototypeChainAndBranch) \ |
82 V(HasInstanceTypeAndBranch) \ | 83 V(HasInstanceTypeAndBranch) \ |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 V(ThisFunction) \ | 157 V(ThisFunction) \ |
157 V(TransitionElementsKind) \ | 158 V(TransitionElementsKind) \ |
158 V(TrapAllocationMemento) \ | 159 V(TrapAllocationMemento) \ |
159 V(TruncateDoubleToIntOrSmi) \ | 160 V(TruncateDoubleToIntOrSmi) \ |
160 V(Typeof) \ | 161 V(Typeof) \ |
161 V(TypeofIsAndBranch) \ | 162 V(TypeofIsAndBranch) \ |
162 V(Uint32ToDouble) \ | 163 V(Uint32ToDouble) \ |
163 V(UnknownOSRValue) \ | 164 V(UnknownOSRValue) \ |
164 V(WrapReceiver) | 165 V(WrapReceiver) |
165 | 166 |
166 | |
167 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ | 167 #define DECLARE_CONCRETE_INSTRUCTION(type, mnemonic) \ |
168 Opcode opcode() const final { return LInstruction::k##type; } \ | 168 Opcode opcode() const final { return LInstruction::k##type; } \ |
169 void CompileToNative(LCodeGen* generator) final; \ | 169 void CompileToNative(LCodeGen* generator) final; \ |
170 const char* Mnemonic() const final { return mnemonic; } \ | 170 const char* Mnemonic() const final { return mnemonic; } \ |
171 static L##type* cast(LInstruction* instr) { \ | 171 static L##type* cast(LInstruction* instr) { \ |
172 DCHECK(instr->Is##type()); \ | 172 DCHECK(instr->Is##type()); \ |
173 return reinterpret_cast<L##type*>(instr); \ | 173 return reinterpret_cast<L##type*>(instr); \ |
174 } | 174 } |
175 | 175 |
176 | 176 |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
619 LOperand* context() { return inputs_[0]; } | 619 LOperand* context() { return inputs_[0]; } |
620 LOperand* size() { return inputs_[1]; } | 620 LOperand* size() { return inputs_[1]; } |
621 LOperand* temp1() { return temps_[0]; } | 621 LOperand* temp1() { return temps_[0]; } |
622 LOperand* temp2() { return temps_[1]; } | 622 LOperand* temp2() { return temps_[1]; } |
623 LOperand* temp3() { return temps_[2]; } | 623 LOperand* temp3() { return temps_[2]; } |
624 | 624 |
625 DECLARE_CONCRETE_INSTRUCTION(Allocate, "allocate") | 625 DECLARE_CONCRETE_INSTRUCTION(Allocate, "allocate") |
626 DECLARE_HYDROGEN_ACCESSOR(Allocate) | 626 DECLARE_HYDROGEN_ACCESSOR(Allocate) |
627 }; | 627 }; |
628 | 628 |
| 629 class LFastAllocate final : public LTemplateInstruction<1, 1, 2> { |
| 630 public: |
| 631 LFastAllocate(LOperand* size, LOperand* temp1, LOperand* temp2) { |
| 632 inputs_[0] = size; |
| 633 temps_[0] = temp1; |
| 634 temps_[1] = temp2; |
| 635 } |
| 636 |
| 637 LOperand* size() { return inputs_[0]; } |
| 638 LOperand* temp1() { return temps_[0]; } |
| 639 LOperand* temp2() { return temps_[1]; } |
| 640 |
| 641 DECLARE_CONCRETE_INSTRUCTION(FastAllocate, "fast-allocate") |
| 642 DECLARE_HYDROGEN_ACCESSOR(Allocate) |
| 643 }; |
629 | 644 |
630 class LApplyArguments final : public LTemplateInstruction<1, 4, 0> { | 645 class LApplyArguments final : public LTemplateInstruction<1, 4, 0> { |
631 public: | 646 public: |
632 LApplyArguments(LOperand* function, | 647 LApplyArguments(LOperand* function, |
633 LOperand* receiver, | 648 LOperand* receiver, |
634 LOperand* length, | 649 LOperand* length, |
635 LOperand* elements) { | 650 LOperand* elements) { |
636 inputs_[0] = function; | 651 inputs_[0] = function; |
637 inputs_[1] = receiver; | 652 inputs_[1] = receiver; |
638 inputs_[2] = length; | 653 inputs_[2] = length; |
(...skipping 2387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3026 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); | 3041 DISALLOW_COPY_AND_ASSIGN(LChunkBuilder); |
3027 }; | 3042 }; |
3028 | 3043 |
3029 #undef DECLARE_HYDROGEN_ACCESSOR | 3044 #undef DECLARE_HYDROGEN_ACCESSOR |
3030 #undef DECLARE_CONCRETE_INSTRUCTION | 3045 #undef DECLARE_CONCRETE_INSTRUCTION |
3031 | 3046 |
3032 } // namespace internal | 3047 } // namespace internal |
3033 } // namespace v8 | 3048 } // namespace v8 |
3034 | 3049 |
3035 #endif // V8_CRANKSHAFT_ARM64_LITHIUM_ARM64_H_ | 3050 #endif // V8_CRANKSHAFT_ARM64_LITHIUM_ARM64_H_ |
OLD | NEW |