[PATCH] D139609: [AArch64][DAGCombiner] fold BIC from AND in dagcombiner

chenglin.bi via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 8 00:39:24 PST 2022


bcl5980 created this revision.
bcl5980 added reviewers: dmgreen, efriedma, mingmingl.
Herald added subscribers: hiraditya, kristof.beyls.
Herald added a project: All.
bcl5980 requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This patch add a new target ISD `AArch64ISD::SBIC` to represent scalar version instruction `bic`.
And select the ISD in the stage combine from this pattern:
(~X | C) & Y --> bic Y, (X & ~C)


https://reviews.llvm.org/D139609

Files:
  llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
  llvm/lib/Target/AArch64/AArch64ISelLowering.h
  llvm/lib/Target/AArch64/AArch64InstrInfo.td
  llvm/test/CodeGen/AArch64/logical-op-with-not.ll
  llvm/test/CodeGen/AArch64/shiftregister-from-and.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139609.481172.patch
Type: text/x-patch
Size: 5796 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221208/78df871b/attachment.bin>


More information about the llvm-commits mailing list