[all-commits] [llvm/llvm-project] 2b4a1d: [RISCV] Improve codegen for shuffles with LHS/RHS ...
Fraser Cormack via All-commits
all-commits at lists.llvm.org
Mon Aug 9 02:41:13 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 2b4a1d4b86f63dc8e60632985c63b7b72d0fe77c
https://github.com/llvm/llvm-project/commit/2b4a1d4b86f63dc8e60632985c63b7b72d0fe77c
Author: Fraser Cormack <fraser at codeplay.com>
Date: 2021-08-09 (Mon, 09 Aug 2021)
Changed paths:
M llvm/lib/Target/RISCV/RISCVISelLowering.cpp
M llvm/lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td
M llvm/test/CodeGen/RISCV/rvv/fixed-vectors-fp-buildvec.ll
M llvm/test/CodeGen/RISCV/rvv/fixed-vectors-fp-shuffles.ll
M llvm/test/CodeGen/RISCV/rvv/fixed-vectors-int-shuffles.ll
Log Message:
-----------
[RISCV] Improve codegen for shuffles with LHS/RHS splats
Shuffles which are broken into separate halves reveal splats in which
a half is accessed via one index; such operations can be optimized to
use "vrgather.vi".
This optimization could be achieved by adding extra patterns to match
`vrgather_vv_vl` which uses a splat as an index operand, but this patch
instead identifies splat earlier. This way, future optimizations can
build on top of the data gathered here, e.g., to splat-gather dominant
indices and insert any leftovers.
Reviewed By: craig.topper
Differential Revision: https://reviews.llvm.org/D107449
More information about the All-commits
mailing list