From 1ca997078c2cf607dfc074a19f822e38fa716f58 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 14 Jan 2007 19:41:24 +0000 Subject: [PATCH] add accessors llvm-svn: 33207 --- llvm/include/llvm/Instructions.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/llvm/include/llvm/Instructions.h b/llvm/include/llvm/Instructions.h index cbcc0974e49c..3a88b990749a 100644 --- a/llvm/include/llvm/Instructions.h +++ b/llvm/include/llvm/Instructions.h @@ -467,6 +467,9 @@ public: /// @brief Return the predicate for this instruction. Predicate getPredicate() const { return Predicate(SubclassData); } + /// @brief Set the predicate for this instruction to the specified value. + void setPredicate(Predicate P) { SubclassData = P; } + /// For example, EQ -> NE, UGT -> ULE, SLT -> SGE, etc. /// @returns the inverse predicate for the instruction's current predicate. /// @brief Return the inverse of the instruction's predicate. @@ -609,6 +612,9 @@ public: /// @brief Return the predicate for this instruction. Predicate getPredicate() const { return Predicate(SubclassData); } + /// @brief Set the predicate for this instruction to the specified value. + void setPredicate(Predicate P) { SubclassData = P; } + /// For example, OEQ -> UNE, UGT -> OLE, OLT -> UGE, etc. /// @returns the inverse predicate for the instructions current predicate. /// @brief Return the inverse of the predicate