[PATCH] D55813: [X86] Add isel patterns to match BMI/TBMI instructions when lowering has turned the root nodes into one of the flag producing binops.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 18 00:52:45 PST 2018


craig.topper created this revision.
craig.topper added reviewers: RKSimon, spatel.

This fixes the patterns that have or/and as a root. 'and' is still broken because lowering keeps a CMP and we match it and the and to TEST. To fix this we'll probably need some custom code in X86ISelDAGToDAG or something. I had to look for uses of the CF flag because all these nodes have non-standard CF flag behavior. A real or/xor would always clear CF. In practice we shouldn't be using the CF flag from these nodes as far as I know.


Repository:
  rL LLVM

https://reviews.llvm.org/D55813

Files:
  lib/Target/X86/X86ISelDAGToDAG.cpp
  lib/Target/X86/X86InstrInfo.td
  test/CodeGen/X86/bmi.ll
  test/CodeGen/X86/tbm_patterns.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D55813.178614.patch
Type: text/x-patch
Size: 10189 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181218/8b4b92cb/attachment.bin>


More information about the llvm-commits mailing list