[PATCH] D128582: Move SeparateConstOffsetFromGEPPass() before LSR() and enable EnableGEPOpt by default.
Shubham Narlawar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 21 08:28:10 PDT 2022
gsocshubham added inline comments.
================
Comment at: llvm/test/CodeGen/AArch64/cond-br-tuning.ll:36
%c = add nsw i32 %a, %b
- %d = icmp ne i32 %c, 0
+ %d = icmp ne i32 %c, 10
br i1 %d, label %L1, label %L2
----------------
dmgreen wrote:
> gsocshubham wrote:
> > dmgreen wrote:
> > > %d = icmp ne i32 %c, 10
> > Do you mean it to change it to `%d = icmp ne i32 %c, 0`?
> >
> > It is already `%d = icmp ne i32 %c, 10`
> Yeah sorry, that is what I meant. The store should be storing a value that isn't 0, so the csel isn't optimized away. The cmp should still not be present (it does get optimized, as it can re-use the adds flags).
Done.
================
Comment at: llvm/test/CodeGen/AArch64/cond-br-tuning.ll:39
L1:
store i32 0, i32* %ptr, align 4
ret void
----------------
dmgreen wrote:
> store i32 10, i32* %ptr, align 4
Done.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D128582/new/
https://reviews.llvm.org/D128582
More information about the llvm-commits
mailing list