[PATCH] D115242: [ARM] Handle splats of constants for MVE qr instruction

Dave Green via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 7 04:53:52 PST 2021


dmgreen created this revision.
dmgreen added reviewers: SjoerdMeijer, samtebbs, simon_tatham, ostannard.
Herald added subscribers: hiraditya, kristof.beyls.
dmgreen requested review of this revision.
Herald added a project: LLVM.

Some MVE instructions have "qr" variants that take a Q and R register, splatting the R register for each lane. This is usually handled fine for standard splats as we sink the splat into the loop and combine the resulting dup into the qr instruction. It does not work for constant splats though, as we generate a vmovimm or constant pool load instead.

The intercepts that, generating a vdup of the constant instead where we can turn the result into a qr instruction variant.


https://reviews.llvm.org/D115242

Files:
  llvm/lib/Target/ARM/ARMISelLowering.cpp
  llvm/lib/Target/ARM/ARMInstrMVE.td
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/exitcount.ll
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/lsr-profitable-chain.ll
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/remat-vctp.ll
  llvm/test/CodeGen/Thumb2/mve-be.ll
  llvm/test/CodeGen/Thumb2/mve-blockplacement.ll
  llvm/test/CodeGen/Thumb2/mve-ctpop.ll
  llvm/test/CodeGen/Thumb2/mve-gather-increment.ll
  llvm/test/CodeGen/Thumb2/mve-gather-ind16-scaled.ll
  llvm/test/CodeGen/Thumb2/mve-gather-ind32-scaled.ll
  llvm/test/CodeGen/Thumb2/mve-gather-ind32-unscaled.ll
  llvm/test/CodeGen/Thumb2/mve-gather-ind8-unscaled.ll
  llvm/test/CodeGen/Thumb2/mve-gather-ptrs.ll
  llvm/test/CodeGen/Thumb2/mve-gather-scatter-optimisation.ll
  llvm/test/CodeGen/Thumb2/mve-gather-scatter-ptr-address.ll
  llvm/test/CodeGen/Thumb2/mve-gather-scatter-tailpred.ll
  llvm/test/CodeGen/Thumb2/mve-halving.ll
  llvm/test/CodeGen/Thumb2/mve-phireg.ll
  llvm/test/CodeGen/Thumb2/mve-pred-vctpvpsel.ll
  llvm/test/CodeGen/Thumb2/mve-qrintrsplat.ll
  llvm/test/CodeGen/Thumb2/mve-scatter-increment.ll
  llvm/test/CodeGen/Thumb2/mve-scatter-ind16-scaled.ll
  llvm/test/CodeGen/Thumb2/mve-scatter-ind32-scaled.ll
  llvm/test/CodeGen/Thumb2/mve-scatter-ind8-unscaled.ll
  llvm/test/CodeGen/Thumb2/mve-scatter-ptrs.ll
  llvm/test/CodeGen/Thumb2/mve-selectcc.ll
  llvm/test/CodeGen/Thumb2/mve-vhadd.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D115242.392354.patch
Type: text/x-patch
Size: 142286 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211207/3ecd7e7a/attachment-0001.bin>


More information about the llvm-commits mailing list