[llvm] [RISCV] Fix missing scaling by LMUL in cost model (PR #73342)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 28 21:29:11 PST 2023
================
@@ -1429,13 +1430,13 @@ InstructionCost RISCVTTIImpl::getCmpSelInstrCost(unsigned Opcode, Type *ValTy,
// vmandn.mm v8, v8, v9
// vmand.mm v9, v0, v9
// vmor.mm v0, v9, v8
- return LT.first * 5;
+ return LT.first * TLI->getLMULCost(LT.second) * 5;
----------------
topperc wrote:
3 of these instructions are mask instructions that only operate on at most VLEN bits. They shouldn't scale with LMUL.
https://github.com/llvm/llvm-project/pull/73342
More information about the llvm-commits
mailing list