diff options
author | Owen Anderson <resistor@mac.com> | 2007-11-12 07:39:39 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2007-11-12 07:39:39 +0000 |
commit | 20ab29068d8a8ec31f26f022634f1e0bc4b1da56 (patch) | |
tree | 075ab2b15d357226cd3cefa2ca5c9540bdeb3dc8 /include/llvm | |
parent | f2fbca68f868122d6df0bfc9952b4e4c3dfb60b7 (diff) |
Add a flag for indirect branch instructions.
Target maintainers: please check that the instructions for your target are correctly marked.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44012 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm')
-rw-r--r-- | include/llvm/Target/TargetInstrInfo.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/llvm/Target/TargetInstrInfo.h b/include/llvm/Target/TargetInstrInfo.h index 1432b5f215..a0596e47c6 100644 --- a/include/llvm/Target/TargetInstrInfo.h +++ b/include/llvm/Target/TargetInstrInfo.h @@ -48,6 +48,7 @@ const unsigned M_BARRIER_FLAG = 1 << 3; const unsigned M_DELAY_SLOT_FLAG = 1 << 4; const unsigned M_LOAD_FLAG = 1 << 5; const unsigned M_STORE_FLAG = 1 << 6; +const unsigned M_INDIRECT_FLAG = 1 << 7; // M_CONVERTIBLE_TO_3_ADDR - This is a 2-address instruction which can be // changed into a 3-address instruction if the first two operands cannot be @@ -237,6 +238,10 @@ public: return get(Opcode).Flags & M_BRANCH_FLAG; } + bool isIndirectBranch(MachineOpCode Opcode) const { + return get(Opcode).Flags & M_INDIRECT_FLAG; + } + /// isBarrier - Returns true if the specified instruction stops control flow /// from executing the instruction immediately following it. Examples include /// unconditional branches and return instructions. |