[PATCH] D139363: [SDAG] try to convert bit set/clear to signbit test when trunc is free

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 6 07:09:18 PST 2022


spatel updated this revision to Diff 480478.
spatel marked an inline comment as done.
spatel edited the summary of this revision.
spatel added a comment.

Patch updated:

1. Added source type legality check to avoid possible regression on x86 test; this also inhibits what looked like a small win for RISCV.
2. Added TODO comment about easing that constraint.
3. Moved hasOneUse() check to end of predicates.


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

https://reviews.llvm.org/D139363

Files:
  llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
  llvm/test/CodeGen/AArch64/signbit-test.ll
  llvm/test/CodeGen/X86/btq.ll
  llvm/test/CodeGen/X86/masked_compressstore.ll
  llvm/test/CodeGen/X86/masked_expandload.ll
  llvm/test/CodeGen/X86/masked_gather.ll
  llvm/test/CodeGen/X86/masked_load.ll
  llvm/test/CodeGen/X86/masked_store.ll
  llvm/test/CodeGen/X86/masked_store_trunc.ll
  llvm/test/CodeGen/X86/masked_store_trunc_ssat.ll
  llvm/test/CodeGen/X86/masked_store_trunc_usat.ll
  llvm/test/CodeGen/X86/omit-urem-of-power-of-two-or-zero-when-comparing-with-zero.ll
  llvm/test/CodeGen/X86/signbit-test.ll
  llvm/test/CodeGen/X86/test-vs-bittest.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139363.480478.patch
Type: text/x-patch
Size: 130522 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221206/06e7c643/attachment-0001.bin>


More information about the llvm-commits mailing list