@@ -4901,8 +4901,8 @@ calculateRegisterUsage(VPlan &Plan, ArrayRef<ElementCount> VFs,
49014901 // recipe that is the key.
49024902 using IntervalMap = SmallDenseMap<VPRecipeBase *, unsigned , 16 >;
49034903
4904- // Maps recipe to its index .
4905- SmallVector<VPRecipeBase *, 64 > IdxToRecipe ;
4904+ // Maps indices to recipes .
4905+ SmallVector<VPRecipeBase *, 64 > Idx2Recipe ;
49064906 // Marks the end of each interval.
49074907 IntervalMap EndPoint;
49084908 // Saves the list of recipe indices that are used in the loop.
@@ -4919,7 +4919,7 @@ calculateRegisterUsage(VPlan &Plan, ArrayRef<ElementCount> VFs,
49194919 if (!VPBB->getParent ())
49204920 break ;
49214921 for (VPRecipeBase &R : *VPBB) {
4922- IdxToRecipe .push_back (&R);
4922+ Idx2Recipe .push_back (&R);
49234923
49244924 // Save the end location of each USE.
49254925 for (VPValue *U : R.operands ()) {
@@ -4940,7 +4940,7 @@ calculateRegisterUsage(VPlan &Plan, ArrayRef<ElementCount> VFs,
49404940 }
49414941
49424942 // Overwrite previous end points.
4943- EndPoint[DefR] = IdxToRecipe .size ();
4943+ EndPoint[DefR] = Idx2Recipe .size ();
49444944 Ends.insert (DefR);
49454945 }
49464946 }
@@ -4949,7 +4949,7 @@ calculateRegisterUsage(VPlan &Plan, ArrayRef<ElementCount> VFs,
49494949 // exiting block, where their increment will get materialized eventually.
49504950 for (auto &R : Plan.getVectorLoopRegion ()->getEntryBasicBlock ()->phis ()) {
49514951 if (isa<VPWidenIntOrFpInductionRecipe>(&R)) {
4952- EndPoint[&R] = IdxToRecipe .size ();
4952+ EndPoint[&R] = Idx2Recipe .size ();
49534953 Ends.insert (&R);
49544954 }
49554955 }
@@ -4981,8 +4981,8 @@ calculateRegisterUsage(VPlan &Plan, ArrayRef<ElementCount> VFs,
49814981 return TTICapture.getRegUsageForType (VectorType::get (Ty, VF));
49824982 };
49834983
4984- for (unsigned int Idx = 0 , Sz = IdxToRecipe .size (); Idx < Sz; ++Idx) {
4985- VPRecipeBase *R = IdxToRecipe [Idx];
4984+ for (unsigned int Idx = 0 , Sz = Idx2Recipe .size (); Idx < Sz; ++Idx) {
4985+ VPRecipeBase *R = Idx2Recipe [Idx];
49864986
49874987 // Remove all of the recipes that end at this location.
49884988 RecipeList &List = TransposeEnds[Idx];
@@ -5398,7 +5398,7 @@ LoopVectorizationCostModel::calculateRegisterUsage(ArrayRef<ElementCount> VFs) {
53985398 // We also search for instructions that are defined outside the loop, but are
53995399 // used inside the loop. We need this number separately from the max-interval
54005400 // usage number because when we unroll, loop-invariant values do not take
5401- // more register .
5401+ // more registers .
54025402 LoopBlocksDFS DFS (TheLoop);
54035403 DFS.perform (LI);
54045404
0 commit comments