diff options
Diffstat (limited to 'include/llvm/Instruction.h')
-rw-r--r-- | include/llvm/Instruction.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/include/llvm/Instruction.h b/include/llvm/Instruction.h index d09c140e14..1b85e91cd0 100644 --- a/include/llvm/Instruction.h +++ b/include/llvm/Instruction.h @@ -97,7 +97,13 @@ public: bool isCommutative() const { return isCommutative(getOpcode()); } static bool isCommutative(unsigned op); - + /// isTrappingInstruction - Return true if the instruction may trap. + /// + bool isTrappingInstruction() const { + return isTrappingInstruction(getOpcode()); + } + static bool isTrappingInstruction(unsigned op); + virtual void print(std::ostream &OS) const; /// Methods for support type inquiry through isa, cast, and dyn_cast: |