[llvm] [VPlan] Replace RdxDesc with RecurKind in VPReductionPHIRecipe (NFC). (PR #142322)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Jul 6 09:34:32 PDT 2025
================
@@ -8310,7 +8307,7 @@ VPRecipeBase *VPRecipeBuilder::tryToCreateWidenRecipe(VPSingleDefRecipe *R,
unsigned ScaleFactor =
----------------
ayalz wrote:
Above
```
const RecurrenceDescriptor &RdxDesc =
Legal->getReductionVars().find(Phi)->second;
```
can be replaced (independently) with
```
const RecurrenceDescriptor &RdxDesc =
Legal->getRecurrenceDescriptor(Phi);
```
?
Similar candidates in
`LoopVectorizationCostModel::collectElementTypesForWidening()`, `LoopVectorizationCostModel::getReductionPatternCost()`.
https://github.com/llvm/llvm-project/pull/142322
More information about the llvm-commits
mailing list