OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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_INTERPRETER_BYTECODES_H_ | 5 #ifndef V8_INTERPRETER_BYTECODES_H_ |
6 #define V8_INTERPRETER_BYTECODES_H_ | 6 #define V8_INTERPRETER_BYTECODES_H_ |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 | 9 |
10 // Clients of this interface shouldn't depend on lots of interpreter internals. | 10 // Clients of this interface shouldn't depend on lots of interpreter internals. |
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
456 // constant pool entry (OperandType::kIdx16). | 456 // constant pool entry (OperandType::kIdx16). |
457 static bool IsJumpConstantWide(Bytecode bytecode); | 457 static bool IsJumpConstantWide(Bytecode bytecode); |
458 | 458 |
459 // Returns true if the bytecode is a jump or conditional jump taking | 459 // Returns true if the bytecode is a jump or conditional jump taking |
460 // any kind of operand. | 460 // any kind of operand. |
461 static bool IsJump(Bytecode bytecode); | 461 static bool IsJump(Bytecode bytecode); |
462 | 462 |
463 // Returns true if the bytecode is a conditional jump, a jump, or a return. | 463 // Returns true if the bytecode is a conditional jump, a jump, or a return. |
464 static bool IsJumpOrReturn(Bytecode bytecode); | 464 static bool IsJumpOrReturn(Bytecode bytecode); |
465 | 465 |
| 466 // Returns true if the bytecode is a call or a constructor call. |
| 467 static bool IsCallOrNew(Bytecode bytecode); |
| 468 |
466 // Returns true if |operand_type| is a register index operand (kIdx8/kIdx16). | 469 // Returns true if |operand_type| is a register index operand (kIdx8/kIdx16). |
467 static bool IsIndexOperandType(OperandType operand_type); | 470 static bool IsIndexOperandType(OperandType operand_type); |
468 | 471 |
469 // Returns true if |operand_type| represents an immediate. | 472 // Returns true if |operand_type| represents an immediate. |
470 static bool IsImmediateOperandType(OperandType operand_type); | 473 static bool IsImmediateOperandType(OperandType operand_type); |
471 | 474 |
472 // Returns true if |operand_type| is a register count operand | 475 // Returns true if |operand_type| is a register count operand |
473 // (kRegCount8/kRegCount16). | 476 // (kRegCount8/kRegCount16). |
474 static bool IsRegisterCountOperandType(OperandType operand_type); | 477 static bool IsRegisterCountOperandType(OperandType operand_type); |
475 | 478 |
(...skipping 20 matching lines...) Expand all Loading... |
496 | 499 |
497 std::ostream& operator<<(std::ostream& os, const Bytecode& bytecode); | 500 std::ostream& operator<<(std::ostream& os, const Bytecode& bytecode); |
498 std::ostream& operator<<(std::ostream& os, const OperandType& operand_type); | 501 std::ostream& operator<<(std::ostream& os, const OperandType& operand_type); |
499 std::ostream& operator<<(std::ostream& os, const OperandSize& operand_type); | 502 std::ostream& operator<<(std::ostream& os, const OperandSize& operand_type); |
500 | 503 |
501 } // namespace interpreter | 504 } // namespace interpreter |
502 } // namespace internal | 505 } // namespace internal |
503 } // namespace v8 | 506 } // namespace v8 |
504 | 507 |
505 #endif // V8_INTERPRETER_BYTECODES_H_ | 508 #endif // V8_INTERPRETER_BYTECODES_H_ |
OLD | NEW |