[llvm] [LoopDeletion] RAUW single-entry header phis after breakLoopBackedge. (PR #106046)
Philip Reames via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 26 09:05:05 PDT 2024
================
@@ -759,6 +759,13 @@ void llvm::breakLoopBackedge(Loop *L, DominatorTree &DT, ScalarEvolution &SE,
DomTreeUpdater DTU(&DT, DomTreeUpdater::UpdateStrategy::Eager);
Header->removePredecessor(Latch, true);
+ for (PHINode &PN : Header->phis()) {
----------------
preames wrote:
Style wise, can this be done in the caller? This routine has a clearly stated purpose, and I generally dislike routines which a bunch of vaguely related things. The need to preserve LCSSA below is somewhat of a counter point.
(Minor, please don't let this be blocking.)
https://github.com/llvm/llvm-project/pull/106046
More information about the llvm-commits
mailing list