[PATCH] D105764: [InstCombine] Fold lshr/ashr(or(neg(x), x), bw-1) --> zext/sext(icmp_ne(x,0)) (PR50816)
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 13 06:01:52 PDT 2021
RKSimon updated this revision to Diff 358244.
RKSimon retitled this revision from "[InstCombine] Fold ashr(or(neg(x),x),bw-1) --> sext(icmp_ne(x,0)) (PR50816)" to "[InstCombine] Fold lshr/ashr(or(neg(x),x),bw-1) --> zext/sext(icmp_ne(x,0)) (PR50816)".
RKSimon edited the summary of this revision.
RKSimon added a comment.
Use m_Deferred and add lshr(or(neg(x),x),bw-1) --> zext(icmp_ne(x,0)) handling
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105764/new/
https://reviews.llvm.org/D105764
Files:
llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
llvm/test/Transforms/InstCombine/sub-ashr-or-to-icmp-select.ll
llvm/test/Transforms/InstCombine/sub-lshr-or-to-icmp-select.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D105764.358244.patch
Type: text/x-patch
Size: 7677 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210713/d6157b3f/attachment.bin>
More information about the llvm-commits
mailing list