[llvm] [ValueTracking] isNonZero trunc of sub of ptr2int's with recursive GEP where pointers are limited to a 32bit alloc. (PR #84933)

via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 22 03:27:15 PDT 2024


bipmis wrote:

> Is there a motivating case for this?

@goldsteinn I believe it would extend the reductions for scenarios where objectSize can be known. 
Additionally it would also speedup the loops which implements a stringLen(recursive gep in loop), which can be possibly be reduced and results in a truncate. A simple case can be as seen in https://gcc.godbolt.org/z/K93v1dsaG

https://github.com/llvm/llvm-project/pull/84933


More information about the llvm-commits mailing list