Skip to content

Commit 9171f77

Browse files
committed
[NFC] Removed unused field.
It should have been removed when poison mode was removed from CanonicalizeOSSALifetime.
1 parent fad35bb commit 9171f77

File tree

1 file changed

+1
-22
lines changed

1 file changed

+1
-22
lines changed

include/swift/SILOptimizer/Utils/CanonicalOSSALifetime.h

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -137,35 +137,14 @@ class CanonicalOSSAConsumeInfo {
137137
/// Record any debug_value instructions found after a final consume.
138138
SmallVector<DebugValueInst *, 8> debugAfterConsume;
139139

140-
/// The set of non-destroy consumes that need to be poisoned. This is
141-
/// determined in two steps. First findOrInsertDestroyInBlock() checks if the
142-
/// lifetime shrank within the block. Second rewriteCopies() checks if the
143-
/// consume is in remnantLiveOutBlock(). Finally injectPoison() inserts new
144-
/// copies and poison destroys for everything in this set.
145-
SmallPtrSetVector<SILInstruction *, 4> needsPoisonConsumes;
146-
147140
public:
148141
void clear() {
149142
finalBlockConsumes.clear();
150143
debugAfterConsume.clear();
151-
needsPoisonConsumes.clear();
152144
}
153145

154146
bool empty() {
155-
return finalBlockConsumes.empty() && debugAfterConsume.empty()
156-
&& needsPoisonConsumes.empty();
157-
}
158-
159-
void recordNeedsPoison(SILInstruction *consume) {
160-
needsPoisonConsumes.insert(consume);
161-
}
162-
163-
bool needsPoison(SILInstruction *consume) const {
164-
return needsPoisonConsumes.count(consume);
165-
}
166-
167-
ArrayRef<SILInstruction *> getNeedsPoisonConsumes() const {
168-
return needsPoisonConsumes.getArrayRef();
147+
return finalBlockConsumes.empty() && debugAfterConsume.empty();
169148
}
170149

171150
bool hasUnclaimedConsumes() const { return !finalBlockConsumes.empty(); }

0 commit comments

Comments
 (0)