The checks created by LAA only compute a pointer difference and do not need to capture provenance. Use SCEVPtrToAddr instead of SCEVPtrToInt for computations. To avoid regressions while parts of SCEV are migrated to use PtrToAddr this adds logic to rewrite all PtrToInt to PtrToAddr if possible in the created expressions. This is needed to avoid regressions. Similarly, if in the original IR we have a PtrToInt, SCEVExpander tries to re-use it if possible when expanding PtrToAddr. Depends on https://github.com/llvm/llvm-project/pull/178727. Fixes https://github.com/llvm/llvm-project/issues/156978. PR: https://github.com/llvm/llvm-project/pull/178861
23 KiB
23 KiB