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 #ifndef V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ | 5 #ifndef V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ |
6 #define V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ | 6 #define V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ |
7 | 7 |
8 #include <cstring> | 8 #include <cstring> |
9 #include <iosfwd> | 9 #include <iosfwd> |
10 | 10 |
(...skipping 30 matching lines...) Expand all Loading... |
41 V(BinaryOperation) \ | 41 V(BinaryOperation) \ |
42 V(BitwiseBinaryOperation) \ | 42 V(BitwiseBinaryOperation) \ |
43 V(ControlInstruction) \ | 43 V(ControlInstruction) \ |
44 V(Instruction) | 44 V(Instruction) |
45 | 45 |
46 | 46 |
47 #define HYDROGEN_CONCRETE_INSTRUCTION_LIST(V) \ | 47 #define HYDROGEN_CONCRETE_INSTRUCTION_LIST(V) \ |
48 V(AbnormalExit) \ | 48 V(AbnormalExit) \ |
49 V(AccessArgumentsAt) \ | 49 V(AccessArgumentsAt) \ |
50 V(Add) \ | 50 V(Add) \ |
51 V(AllocateBlockContext) \ | |
52 V(Allocate) \ | 51 V(Allocate) \ |
53 V(ApplyArguments) \ | 52 V(ApplyArguments) \ |
54 V(ArgumentsElements) \ | 53 V(ArgumentsElements) \ |
55 V(ArgumentsLength) \ | 54 V(ArgumentsLength) \ |
56 V(ArgumentsObject) \ | 55 V(ArgumentsObject) \ |
57 V(Bitwise) \ | 56 V(Bitwise) \ |
58 V(BlockEntry) \ | 57 V(BlockEntry) \ |
59 V(BoundsCheck) \ | 58 V(BoundsCheck) \ |
60 V(BoundsCheckBaseIndexInformation) \ | 59 V(BoundsCheckBaseIndexInformation) \ |
61 V(Branch) \ | 60 V(Branch) \ |
(...skipping 7599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7661 DECLARE_CONCRETE_INSTRUCTION(StoreFrameContext) | 7660 DECLARE_CONCRETE_INSTRUCTION(StoreFrameContext) |
7662 private: | 7661 private: |
7663 explicit HStoreFrameContext(HValue* context) | 7662 explicit HStoreFrameContext(HValue* context) |
7664 : HUnaryOperation(context) { | 7663 : HUnaryOperation(context) { |
7665 set_representation(Representation::Tagged()); | 7664 set_representation(Representation::Tagged()); |
7666 SetChangesFlag(kContextSlots); | 7665 SetChangesFlag(kContextSlots); |
7667 } | 7666 } |
7668 }; | 7667 }; |
7669 | 7668 |
7670 | 7669 |
7671 class HAllocateBlockContext: public HTemplateInstruction<2> { | |
7672 public: | |
7673 DECLARE_INSTRUCTION_FACTORY_P3(HAllocateBlockContext, HValue*, | |
7674 HValue*, Handle<ScopeInfo>); | |
7675 HValue* context() const { return OperandAt(0); } | |
7676 HValue* function() const { return OperandAt(1); } | |
7677 Handle<ScopeInfo> scope_info() const { return scope_info_; } | |
7678 | |
7679 Representation RequiredInputRepresentation(int index) override { | |
7680 return Representation::Tagged(); | |
7681 } | |
7682 | |
7683 std::ostream& PrintDataTo(std::ostream& os) const override; // NOLINT | |
7684 | |
7685 DECLARE_CONCRETE_INSTRUCTION(AllocateBlockContext) | |
7686 | |
7687 private: | |
7688 HAllocateBlockContext(HValue* context, | |
7689 HValue* function, | |
7690 Handle<ScopeInfo> scope_info) | |
7691 : scope_info_(scope_info) { | |
7692 SetOperandAt(0, context); | |
7693 SetOperandAt(1, function); | |
7694 set_representation(Representation::Tagged()); | |
7695 } | |
7696 | |
7697 Handle<ScopeInfo> scope_info_; | |
7698 }; | |
7699 | |
7700 | |
7701 | 7670 |
7702 #undef DECLARE_INSTRUCTION | 7671 #undef DECLARE_INSTRUCTION |
7703 #undef DECLARE_CONCRETE_INSTRUCTION | 7672 #undef DECLARE_CONCRETE_INSTRUCTION |
7704 | 7673 |
7705 } // namespace internal | 7674 } // namespace internal |
7706 } // namespace v8 | 7675 } // namespace v8 |
7707 | 7676 |
7708 #endif // V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ | 7677 #endif // V8_CRANKSHAFT_HYDROGEN_INSTRUCTIONS_H_ |
OLD | NEW |