[PATCH] D151911: [LVI] Handle icmp of ashr.
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 6 11:21:16 PDT 2023
nikic added a comment.
Can you please add an alive2 proof to the patch description?
================
Comment at: llvm/lib/Analysis/LazyValueInfo.cpp:1153
+ const APInt *ShAmtC, *RHSC;
+ if (EdgePred == CmpInst::ICMP_SGT &&
+ match(LHS, m_AShr(m_Specific(Val), m_APInt(ShAmtC))) &&
----------------
For symmetry reasons, this needs to handle all signed predicates (sgt, sge, slt, sle). The non-strict predicates are non-canonical by themselves, but will appear when the inverse predicate is taken.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D151911/new/
https://reviews.llvm.org/D151911
More information about the llvm-commits
mailing list