[llvm-commits] [llvm] r81862 - /llvm/trunk/lib/VMCore/ConstantFold.cpp
Dan Gohman
gohman at apple.com
Tue Sep 15 09:00:30 PDT 2009
Author: djg
Date: Tue Sep 15 11:00:30 2009
New Revision: 81862
URL: http://llvm.org/viewvc/llvm-project?rev=81862&view=rev
Log:
Fix an accidental inversion of the inbounds flag.
Modified:
llvm/trunk/lib/VMCore/ConstantFold.cpp
Modified: llvm/trunk/lib/VMCore/ConstantFold.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/ConstantFold.cpp?rev=81862&r1=81861&r2=81862&view=diff
==============================================================================
--- llvm/trunk/lib/VMCore/ConstantFold.cpp (original)
+++ llvm/trunk/lib/VMCore/ConstantFold.cpp Tue Sep 15 11:00:30 2009
@@ -1873,10 +1873,10 @@
for (unsigned i = 0; i != NumIdx; ++i)
if (!NewIdxs[i]) NewIdxs[i] = Idxs[i];
return inBounds ?
- ConstantExpr::getGetElementPtr(const_cast<Constant*>(C),
- NewIdxs.data(), NewIdxs.size()) :
ConstantExpr::getInBoundsGetElementPtr(const_cast<Constant*>(C),
- NewIdxs.data(), NewIdxs.size());
+ NewIdxs.data(), NewIdxs.size()) :
+ ConstantExpr::getGetElementPtr(const_cast<Constant*>(C),
+ NewIdxs.data(), NewIdxs.size());
}
// If all indices are known integers and normalized, we can do a simple
More information about the llvm-commits
mailing list