[PATCH] D159147: [DAGCombiner] Combine trunc (splat_vector x) -> splat_vector (trunc x)

Luke Lau via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 29 16:44:38 PDT 2023


luke created this revision.
luke added reviewers: craig.topper, reames, RKSimon.
Herald added subscribers: asb, sunshaoce, pmatos, frasercrmck, luismarques, apazos, sameer.abuasal, s.egerton, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, niosHD, sabuasal, simoncook, johnrusso, rbar, hiraditya, arichardson.
Herald added a project: All.
luke requested review of this revision.
Herald added subscribers: llvm-commits, wangpc, MaskRay.
Herald added a project: LLVM.

>From the discussion in https://reviews.llvm.org/D158853, moving the truncate
into the splat helps more splatted scalar operands get selected on RISC-V, and
also avoids the need for splat_vector_parts on RV32.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D159147

Files:
  llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
  llvm/test/CodeGen/RISCV/rvv/vnsrl-sdnode.ll
  llvm/test/CodeGen/RISCV/rvv/vwsll-sdnode.ll
  llvm/test/CodeGen/RISCV/rvv/vwsll-vp.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D159147.554522.patch
Type: text/x-patch
Size: 17743 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230829/ada11cec/attachment.bin>


More information about the llvm-commits mailing list