[llvm] [RISCV][CostModel] Correct the cost of some reductions (PR #118072)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Sat Nov 30 03:06:43 PST 2024


================
@@ -1470,27 +1470,27 @@ RISCVTTIImpl::getMinMaxReductionCost(Intrinsic::ID IID, VectorType *Ty,
     llvm_unreachable("Unsupported intrinsic");
   case Intrinsic::smax:
     SplitOp = RISCV::VMAX_VV;
-    Opcodes = {RISCV::VMV_S_X, RISCV::VREDMAX_VS, RISCV::VMV_X_S};
+    Opcodes = {RISCV::VREDMAX_VS, RISCV::VMV_X_S};
----------------
lukel97 wrote:

Good catch, can you update the comment above this switch statement as well?

https://github.com/llvm/llvm-project/pull/118072


More information about the llvm-commits mailing list