[PATCH] D151221: [RISCV] Scalarize constant stores of fixed vectors up to 32 bits
Luke Lau via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 23 08:12:13 PDT 2023
luke created this revision.
luke added reviewers: craig.topper, reames, asb, kito-cheng.
Herald added subscribers: jobnoorman, pmatos, VincentWu, vkmr, frasercrmck, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, niosHD, sabuasal, simoncook, johnrusso, rbar, hiraditya, arichardson.
Herald added a project: All.
luke requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead, eopXD, MaskRay.
Herald added a project: LLVM.
For stores of small fixed-length vector constants, we can store them
with a sequence of lui/addi/sh/sw to avoid the cost of building the
vector and the vsetivli toggle.
Note that this only handles vectors that are 32 bits or smaller, but
could be expanded to 64 bits if we know that the constant
materialization cost isn't too high.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D151221
Files:
llvm/lib/Target/RISCV/RISCVISelLowering.cpp
llvm/test/CodeGen/RISCV/rvv/fixed-vectors-int-buildvec.ll
llvm/test/CodeGen/RISCV/rvv/fixed-vectors-store.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151221.524732.patch
Type: text/x-patch
Size: 15845 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230523/c663e7b8/attachment-0001.bin>
More information about the llvm-commits
mailing list