aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Support/ConstantFolder.h
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2010-02-02 12:53:04 +0000
committerDuncan Sands <baldrick@free.fr>2010-02-02 12:53:04 +0000
commit8991d51ddcea31e198aff1fd01c05af2679ee8f8 (patch)
tree09ee28307520a9d70966506f399eb0a0fa256335 /include/llvm/Support/ConstantFolder.h
parent769e2ad872538a203072ecdbb1ad9249a711a0d4 (diff)
downloadexternal_llvm-8991d51ddcea31e198aff1fd01c05af2679ee8f8.tar.gz
external_llvm-8991d51ddcea31e198aff1fd01c05af2679ee8f8.tar.bz2
external_llvm-8991d51ddcea31e198aff1fd01c05af2679ee8f8.zip
Adding missing methods for creating Add, Mul, Neg and Sub with NUW.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95086 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support/ConstantFolder.h')
-rw-r--r--include/llvm/Support/ConstantFolder.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/llvm/Support/ConstantFolder.h b/include/llvm/Support/ConstantFolder.h
index 1339e9fac6..ea6c5fd82a 100644
--- a/include/llvm/Support/ConstantFolder.h
+++ b/include/llvm/Support/ConstantFolder.h
@@ -39,6 +39,9 @@ public:
Constant *CreateNSWAdd(Constant *LHS, Constant *RHS) const {
return ConstantExpr::getNSWAdd(LHS, RHS);
}
+ Constant *CreateNUWAdd(Constant *LHS, Constant *RHS) const {
+ return ConstantExpr::getNUWAdd(LHS, RHS);
+ }
Constant *CreateFAdd(Constant *LHS, Constant *RHS) const {
return ConstantExpr::getFAdd(LHS, RHS);
}
@@ -48,6 +51,9 @@ public:
Constant *CreateNSWSub(Constant *LHS, Constant *RHS) const {
return ConstantExpr::getNSWSub(LHS, RHS);
}
+ Constant *CreateNUWSub(Constant *LHS, Constant *RHS) const {
+ return ConstantExpr::getNUWSub(LHS, RHS);
+ }
Constant *CreateFSub(Constant *LHS, Constant *RHS) const {
return ConstantExpr::getFSub(LHS, RHS);
}
@@ -57,6 +63,9 @@ public:
Constant *CreateNSWMul(Constant *LHS, Constant *RHS) const {
return ConstantExpr::getNSWMul(LHS, RHS);
}
+ Constant *CreateNUWMul(Constant *LHS, Constant *RHS) const {
+ return ConstantExpr::getNUWMul(LHS, RHS);
+ }
Constant *CreateFMul(Constant *LHS, Constant *RHS) const {
return ConstantExpr::getFMul(LHS, RHS);
}
@@ -115,6 +124,9 @@ public:
Constant *CreateNSWNeg(Constant *C) const {
return ConstantExpr::getNSWNeg(C);
}
+ Constant *CreateNUWNeg(Constant *C) const {
+ return ConstantExpr::getNUWNeg(C);
+ }
Constant *CreateFNeg(Constant *C) const {
return ConstantExpr::getFNeg(C);
}