aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Analysis/InstructionSimplify.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Analysis/InstructionSimplify.cpp')
-rw-r--r--llvm/lib/Analysis/InstructionSimplify.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Analysis/InstructionSimplify.cpp b/llvm/lib/Analysis/InstructionSimplify.cpp
index 8b2aa6b..0089586 100644
--- a/llvm/lib/Analysis/InstructionSimplify.cpp
+++ b/llvm/lib/Analysis/InstructionSimplify.cpp
@@ -5068,9 +5068,8 @@ static Value *simplifyGEPInst(Type *SrcTy, Value *Ptr,
return nullptr;
if (!ConstantExpr::isSupportedGetElementPtr(SrcTy))
- // TODO(gep_nowrap): Pass on the whole GEPNoWrapFlags.
- return ConstantFoldGetElementPtr(SrcTy, cast<Constant>(Ptr),
- NW.isInBounds(), std::nullopt, Indices);
+ return ConstantFoldGetElementPtr(SrcTy, cast<Constant>(Ptr), std::nullopt,
+ Indices);
auto *CE =
ConstantExpr::getGetElementPtr(SrcTy, cast<Constant>(Ptr), Indices, NW);