Skip to content

Commit a48612c

Browse files
committed
!fixup VPLiveInsToFree -> VPLiveIns.
1 parent b25de79 commit a48612c

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

llvm/lib/Transforms/Vectorize/VPlan.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -870,7 +870,7 @@ VPlan::~VPlan() {
870870
}
871871
delete VPB;
872872
}
873-
for (VPValue *VPV : VPLiveInsToFree)
873+
for (VPValue *VPV : getLiveIns())
874874
delete VPV;
875875
if (BackedgeTakenCount)
876876
delete BackedgeTakenCount;
@@ -1233,7 +1233,7 @@ VPlan *VPlan::duplicate() {
12331233
// Create VPlan, clone live-ins and remap operands in the cloned blocks.
12341234
auto *NewPlan = new VPlan(cast<VPBasicBlock>(NewEntry), NewScalarHeader);
12351235
DenseMap<VPValue *, VPValue *> Old2NewVPValues;
1236-
for (VPValue *OldLiveIn : VPLiveInsToFree) {
1236+
for (VPValue *OldLiveIn : getLiveIns()) {
12371237
Old2NewVPValues[OldLiveIn] =
12381238
NewPlan->getOrAddLiveIn(OldLiveIn->getLiveInIRValue());
12391239
}
@@ -1537,7 +1537,7 @@ void VPSlotTracker::assignNames(const VPlan &Plan) {
15371537
assignName(&Plan.VectorTripCount);
15381538
if (Plan.BackedgeTakenCount)
15391539
assignName(Plan.BackedgeTakenCount);
1540-
for (VPValue *LI : Plan.VPLiveInsToFree)
1540+
for (VPValue *LI : Plan.getLiveIns())
15411541
assignName(LI);
15421542

15431543
ReversePostOrderTraversal<VPBlockDeepTraversalWrapper<const VPBlockBase *>>

llvm/lib/Transforms/Vectorize/VPlan.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3502,7 +3502,7 @@ class VPlan {
35023502

35033503
/// Contains all the external definitions created for this VPlan. External
35043504
/// definitions are VPValues that hold a pointer to their underlying IR.
3505-
SmallVector<VPValue *, 16> VPLiveInsToFree;
3505+
SmallVector<VPValue *, 16> VPLiveIns;
35063506

35073507
/// Mapping from SCEVs to the VPValues representing their expansions.
35083508
/// NOTE: This mapping is temporary and will be removed once all users have
@@ -3692,7 +3692,7 @@ class VPlan {
36923692
auto [It, Inserted] = Value2VPValue.try_emplace(V);
36933693
if (Inserted) {
36943694
VPValue *VPV = new VPValue(V);
3695-
VPLiveInsToFree.push_back(VPV);
3695+
VPLiveIns.push_back(VPV);
36963696
assert(VPV->isLiveIn() && "VPV must be a live-in.");
36973697
It->second = VPV;
36983698
}
@@ -3705,7 +3705,7 @@ class VPlan {
37053705
VPValue *getLiveIn(Value *V) const { return Value2VPValue.lookup(V); }
37063706

37073707
/// Return the list of live-in VPValues available in the VPlan.
3708-
ArrayRef<VPValue *> getLiveIns() const { return VPLiveInsToFree; }
3708+
ArrayRef<VPValue *> getLiveIns() const { return VPLiveIns; }
37093709

37103710
#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
37113711
/// Print the live-ins of this VPlan to \p O.

0 commit comments

Comments
 (0)