[PATCH] D117252: [InstCombine] Fold ashr-exact into a icmp-ugt.

Nadav Rotem via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 13 19:44:15 PST 2022


nadav updated this revision to Diff 399871.
nadav added a comment.

@craig.topper thank you for the review. I removed the two predicated that are canonicalized before this method is called (ICMP_SGE and ICMP_UGE). I also used the script update_test_checks.py to update the check lines. I also verified with alive2 that the transformation is correct for ICMP_UGT, but only when the exact flag is present  (link:  https://alive2.llvm.org/ce/z/qBhxAM).


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117252/new/

https://reviews.llvm.org/D117252

Files:
  lib/Transforms/InstCombine/InstCombineCompares.cpp
  test/Transforms/InstCombine/icmp-shr-lt-gt.ll
  test/Transforms/InstCombine/icmp-shr.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D117252.399871.patch
Type: text/x-patch
Size: 4926 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220114/3505f242/attachment.bin>


More information about the llvm-commits mailing list