[llvm] [LoopInfo] Add recompute() and use it in SimpleLoopUnswitch (PR #213514)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 3 19:23:24 PDT 2026
================
@@ -854,6 +862,20 @@ template <class BlockT, class LoopT> class LoopInfoBase {
void analyze(const DominatorTreeBase<BlockT, false> &DomTree);
///@}
+ /// Rebuild the loop forest from the CFG, reusing the existing loop object for
+ /// every block that still heads a loop. Analyses that key on loop pointers,
----------------
MaskRay wrote:
Agreed it's worth pursuing separately. `Loop *` is also the loop pass manager's currency (`run(Loop &L, ...)`, LPMUpdater, LAM cache keys), so it's a wide change.
https://github.com/llvm/llvm-project/pull/213514
More information about the llvm-commits
mailing list