[RISCV] Incorporate LMUL into costs for arithmetic and shuffles
authorPhilip Reames <preames@rivosinc.com>
Thu, 1 Dec 2022 18:37:44 +0000 (10:37 -0800)
committerPhilip Reames <listmail@philipreames.com>
Thu, 1 Dec 2022 18:46:27 +0000 (10:46 -0800)
commit73eacf94e03b1e1ee8a3c76dbf4e336300c376b9
tree63f1959001487d3d5e615a5d59d80b94c98abf81
parent010a8f7a90bf6e6d77f07f0a02dd8a63dfeb32da
[RISCV] Incorporate LMUL into costs for arithmetic and shuffles

This reuses the routine implemented in 0e6f0b7 to implement several existing TODOs. Many of the operations scale linearly with LMUL; this change represents that in the cost model.

Differential Revision: https://reviews.llvm.org/D139039
llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp
llvm/test/Analysis/CostModel/RISCV/active_lane_mask.ll
llvm/test/Analysis/CostModel/RISCV/arith-fp.ll
llvm/test/Analysis/CostModel/RISCV/arith-int.ll
llvm/test/Analysis/CostModel/RISCV/rvv-intrinsics.ll
llvm/test/Analysis/CostModel/RISCV/rvv-shuffle.ll
llvm/test/Analysis/CostModel/RISCV/splice.ll
llvm/test/Transforms/LoopVectorize/RISCV/riscv-vector-reverse.ll