Skip to content

Commit 17ab0ad

Browse files
committed
EscapeAnalysis: Do not create defer edges for block arguemnts.
That appears to have been a partial workaround for the real problem that usepoints need to be propagated across the entire defer web. This is now solved by considering use points on the reference node's content, not the reference node itself.
1 parent 7fb4e21 commit 17ab0ad

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

lib/SILOptimizer/Analysis/EscapeAnalysis.cpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -826,15 +826,6 @@ void EscapeAnalysis::ConnectionGraph::computeUsePoints() {
826826
#endif
827827
// First scan the whole function and add relevant instructions as use-points.
828828
for (auto &BB : *F) {
829-
for (SILArgument *BBArg : BB.getArguments()) {
830-
/// In addition to releasing instructions (see below) we also add block
831-
/// arguments as use points. In case of loops, block arguments can
832-
/// "extend" the liferange of a reference in upward direction.
833-
if (CGNode *ArgNode = lookupNode(BBArg)) {
834-
addUsePoint(ArgNode, BBArg);
835-
}
836-
}
837-
838829
for (auto &I : BB) {
839830
switch (I.getKind()) {
840831
#define ALWAYS_OR_SOMETIMES_LOADABLE_CHECKED_REF_STORAGE(Name, ...) \

0 commit comments

Comments
 (0)