================ @@ -1986,10 +1986,12 @@ void VPReverseVectorPointerRecipe::execute(VPTransformState &State) { // LastLane = 1 - RunTimeVF Value *LastLane = Builder.CreateSub(ConstantInt::get(IndexTy, 1), RunTimeVF); Value *Ptr = State.get(getOperand(0), VPLane(0)); - Value *ResultPtr = - Builder.CreateGEP(IndexedTy, Ptr, NumElt, "", getGEPNoWrapFlags()); - ResultPtr = Builder.CreateGEP(IndexedTy, ResultPtr, LastLane, "", - getGEPNoWrapFlags()); + Value *ResultPtr = Builder.CreateGEP( + IndexedTy, Ptr, NumElt, "", + getGEPNoWrapFlags().withoutInBounds().withoutNoUnsignedSignedWrap()); + ResultPtr = Builder.CreateGEP( + IndexedTy, ResultPtr, LastLane, "", + getGEPNoWrapFlags().withoutInBounds().withoutNoUnsignedSignedWrap()); ---------------- nikic wrote:
Note that inbounds is the only flag that can be set for this recipe, see https://github.com/llvm/llvm-project/blob/a9034d0b7ff3b0bf90239f6b46ada7f3490b6904/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp#L8441-L8442. So effectively this means that we never use flags here. It would be cleaner to not associate flags with this recipe in the first place, I think. https://github.com/llvm/llvm-project/pull/120730 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits