[llvm] [LV] Add scalar load/stores to VPReplicateRecipe::computeCost (PR #153218)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 4 04:56:33 PDT 2025


================
@@ -5205,6 +5205,8 @@ LoopVectorizationCostModel::getConsecutiveMemOpCost(Instruction *I,
     Cost += TTI.getMaskedMemoryOpCost(I->getOpcode(), VectorTy, Alignment, AS,
                                       CostKind);
   } else {
+    // TODO: Is this right? Operand 0 has a different meaning for loads and
+    // stores.
----------------
fhahn wrote:

Just checking if you saw this comment? Given the above, the comment should be removed here and the documentation for the TTI functions improved/clarified

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


More information about the llvm-commits mailing list