================ @@ -1079,6 +1081,8 @@ bool SeparateConstOffsetFromGEP::splitGEP(GetElementPtrInst *GEP) { // and the old index if they are not used. RecursivelyDeleteTriviallyDeadInstructions(UserChainTail); RecursivelyDeleteTriviallyDeadInstructions(OldIdx); + MayRecoverInbounds = + MayRecoverInbounds && computeKnownBits(NewIdx, *DL).isNonNegative(); ---------------- arsenm wrote:
Needs some negative tests where computeKnownBits missed by a bit https://github.com/llvm/llvm-project/pull/130617 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits