[PATCH] D23446: [X86] Enable setcc to srl(ctlz) transformation on btver2 architectures.

pierre gousseau via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 4 09:44:57 PDT 2016


pgousseau updated this revision to Diff 73497.
pgousseau added a comment.

Hi Simon/Sanjay,

Following up with with the previous comments, this patch contains:

- Use of DAG.getZextOrTrunc as per Simon's comment.
- Removed support for the simple case.
- Added handling of OR based patterns.
- Added a case for SRL nodes in 'isTypeDesirableForOp()' as to favor 32 bits encoding when targetting X86.
- Added support for multiple OR patterns eg: (a1||a2||a3||a4||a5)

Let me know what you think,

Thanks!


https://reviews.llvm.org/D23446

Files:
  include/llvm/Target/TargetLowering.h
  lib/CodeGen/SelectionDAG/TargetLowering.cpp
  lib/Target/PowerPC/PPCISelLowering.cpp
  lib/Target/X86/X86.td
  lib/Target/X86/X86ISelLowering.cpp
  lib/Target/X86/X86ISelLowering.h
  lib/Target/X86/X86InstrInfo.td
  lib/Target/X86/X86Subtarget.cpp
  lib/Target/X86/X86Subtarget.h
  test/CodeGen/X86/lzcnt-zext-cmp.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D23446.73497.patch
Type: text/x-patch
Size: 19026 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161004/d3b1fa6e/attachment.bin>


More information about the llvm-commits mailing list