Skip to content

Commit d2b3339

Browse files
author
git apple-llvm automerger
committed
Merge commit '976641062e77' from llvm.org/main into next
2 parents 554726f + 9766410 commit d2b3339

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

flang/lib/Optimizer/Analysis/AliasAnalysis.cpp

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -641,14 +641,18 @@ AliasAnalysis::Source AliasAnalysis::getSource(mlir::Value v,
641641
} else if (isDummyArgument(def)) {
642642
defOp = nullptr;
643643
v = def;
644+
} else {
645+
type = SourceKind::Indirect;
644646
}
645-
647+
// TODO: This assignment is redundant but somehow works around an
648+
// apparent MSVC bug reporting "undeclared identifier" at the next
649+
// "breakFromLoop = true;". See
650+
// <https://github.com/llvm/llvm-project/pull/127845#issuecomment-2669829610>.
646651
breakFromLoop = true;
647-
return;
652+
} else {
653+
// No further tracking for addresses loaded from memory for now.
654+
type = SourceKind::Indirect;
648655
}
649-
650-
// No further tracking for addresses loaded from memory for now.
651-
type = SourceKind::Indirect;
652656
breakFromLoop = true;
653657
})
654658
.Case<fir::AddrOfOp>([&](auto op) {

0 commit comments

Comments
 (0)