diff options
author | Dan Gohman <gohman@apple.com> | 2009-08-11 17:05:24 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-08-11 17:05:24 +0000 |
commit | 58f4d89a10ee340577a3a84a5d10cd17cf820c13 (patch) | |
tree | 7d6b0aa3c036234338034a7f568903ac3bebd606 /llvm/include/llvm/Support/ConstantFolder.h | |
parent | d6c611e6e8fb869d99feb0c1f530b13f974d54d0 (diff) | |
download | bcm5719-llvm-58f4d89a10ee340577a3a84a5d10cd17cf820c13.tar.gz bcm5719-llvm-58f4d89a10ee340577a3a84a5d10cd17cf820c13.zip |
Add convenience functions for creating exact sdiv operators, and
use them in CreatePtrDiff.
llvm-svn: 78682
Diffstat (limited to 'llvm/include/llvm/Support/ConstantFolder.h')
-rw-r--r-- | llvm/include/llvm/Support/ConstantFolder.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/include/llvm/Support/ConstantFolder.h b/llvm/include/llvm/Support/ConstantFolder.h index cb9b0555847..422d1ad00d2 100644 --- a/llvm/include/llvm/Support/ConstantFolder.h +++ b/llvm/include/llvm/Support/ConstantFolder.h @@ -56,6 +56,9 @@ public: Constant *CreateSDiv(Constant *LHS, Constant *RHS) const { return ConstantExpr::getSDiv(LHS, RHS); } + Constant *CreateExactSDiv(Constant *LHS, Constant *RHS) const { + return ConstantExpr::getExactSDiv(LHS, RHS); + } Constant *CreateFDiv(Constant *LHS, Constant *RHS) const { return ConstantExpr::getFDiv(LHS, RHS); } |