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_COMPILER_OPCODES_H_ | 5 #ifndef V8_COMPILER_OPCODES_H_ |
6 #define V8_COMPILER_OPCODES_H_ | 6 #define V8_COMPILER_OPCODES_H_ |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 | 9 |
10 #include "src/globals.h" | 10 #include "src/globals.h" |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 V(JSConvertReceiver) \ | 168 V(JSConvertReceiver) \ |
169 V(JSForInNext) \ | 169 V(JSForInNext) \ |
170 V(JSForInPrepare) \ | 170 V(JSForInPrepare) \ |
171 V(JSLoadMessage) \ | 171 V(JSLoadMessage) \ |
172 V(JSStoreMessage) \ | 172 V(JSStoreMessage) \ |
173 V(JSLoadModule) \ | 173 V(JSLoadModule) \ |
174 V(JSStoreModule) \ | 174 V(JSStoreModule) \ |
175 V(JSGeneratorStore) \ | 175 V(JSGeneratorStore) \ |
176 V(JSGeneratorRestoreContinuation) \ | 176 V(JSGeneratorRestoreContinuation) \ |
177 V(JSGeneratorRestoreRegister) \ | 177 V(JSGeneratorRestoreRegister) \ |
178 V(JSStackCheck) | 178 V(JSStackCheck) \ |
| 179 V(JSDebugger) |
179 | 180 |
180 #define JS_OP_LIST(V) \ | 181 #define JS_OP_LIST(V) \ |
181 JS_SIMPLE_BINOP_LIST(V) \ | 182 JS_SIMPLE_BINOP_LIST(V) \ |
182 JS_SIMPLE_UNOP_LIST(V) \ | 183 JS_SIMPLE_UNOP_LIST(V) \ |
183 JS_OBJECT_OP_LIST(V) \ | 184 JS_OBJECT_OP_LIST(V) \ |
184 JS_CONTEXT_OP_LIST(V) \ | 185 JS_CONTEXT_OP_LIST(V) \ |
185 JS_OTHER_OP_LIST(V) | 186 JS_OTHER_OP_LIST(V) |
186 | 187 |
187 // Opcodes for VirtuaMachine-level operators. | 188 // Opcodes for VirtuaMachine-level operators. |
188 #define SIMPLIFIED_CHANGE_OP_LIST(V) \ | 189 #define SIMPLIFIED_CHANGE_OP_LIST(V) \ |
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
768 return kStart <= value && value <= kDead; | 769 return kStart <= value && value <= kDead; |
769 } | 770 } |
770 | 771 |
771 // Returns true if opcode for control operator. | 772 // Returns true if opcode for control operator. |
772 static bool IsControlOpcode(Value value) { | 773 static bool IsControlOpcode(Value value) { |
773 return kStart <= value && value <= kEnd; | 774 return kStart <= value && value <= kEnd; |
774 } | 775 } |
775 | 776 |
776 // Returns true if opcode for JavaScript operator. | 777 // Returns true if opcode for JavaScript operator. |
777 static bool IsJsOpcode(Value value) { | 778 static bool IsJsOpcode(Value value) { |
778 return kJSEqual <= value && value <= kJSStackCheck; | 779 return kJSEqual <= value && value <= kJSDebugger; |
779 } | 780 } |
780 | 781 |
781 // Returns true if opcode for constant operator. | 782 // Returns true if opcode for constant operator. |
782 static bool IsConstantOpcode(Value value) { | 783 static bool IsConstantOpcode(Value value) { |
783 return kInt32Constant <= value && value <= kRelocatableInt64Constant; | 784 return kInt32Constant <= value && value <= kRelocatableInt64Constant; |
784 } | 785 } |
785 | 786 |
786 static bool IsPhiOpcode(Value value) { | 787 static bool IsPhiOpcode(Value value) { |
787 return value == kPhi || value == kEffectPhi; | 788 return value == kPhi || value == kEffectPhi; |
788 } | 789 } |
(...skipping 23 matching lines...) Expand all Loading... |
812 } | 813 } |
813 }; | 814 }; |
814 | 815 |
815 V8_EXPORT_PRIVATE std::ostream& operator<<(std::ostream&, IrOpcode::Value); | 816 V8_EXPORT_PRIVATE std::ostream& operator<<(std::ostream&, IrOpcode::Value); |
816 | 817 |
817 } // namespace compiler | 818 } // namespace compiler |
818 } // namespace internal | 819 } // namespace internal |
819 } // namespace v8 | 820 } // namespace v8 |
820 | 821 |
821 #endif // V8_COMPILER_OPCODES_H_ | 822 #endif // V8_COMPILER_OPCODES_H_ |
OLD | NEW |