[PATCH] D109963: [AArch64] Split bitmask immediate of bitwise AND operation

JinGu Kang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 17 06:38:53 PDT 2021


jaykang10 created this revision.
jaykang10 added reviewers: t.p.northover, dmgreen, eli.friedman.
Herald added subscribers: hiraditya, kristof.beyls.
jaykang10 requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This patch tries below transformation.

  MOVi32imm + ANDWrr
  ==>
  ANDWri + ANDWri

The MOVi32imm pseudo instruction could be expanded to multiple mov instructions later. Let's try to split the constant operand of MOVi32imm into two bitmask immediates. It makes only two AND instructions intead of multiple `mov + and` instructions.


https://reviews.llvm.org/D109963

Files:
  llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
  llvm/lib/Target/AArch64/AArch64ISelLowering.h
  llvm/lib/Target/AArch64/AArch64InstrFormats.td
  llvm/test/CodeGen/AArch64/aarch64-split-and-bitmask-immediate.ll
  llvm/test/CodeGen/AArch64/unfold-masked-merge-scalar-constmask-innerouter.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D109963.373207.patch
Type: text/x-patch
Size: 6762 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210917/7522fb9f/attachment.bin>


More information about the llvm-commits mailing list