diff options
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp | 7 | 
1 files changed, 7 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp b/llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp index 4e7abfc5bda..fa9dbe240ba 100644 --- a/llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp +++ b/llvm/lib/Transforms/Scalar/SimpleLoopUnswitch.cpp @@ -2140,6 +2140,13 @@ static void unswitchNontrivialInvariants(      // the branch in the split block.      buildPartialUnswitchConditionalBranch(*SplitBB, Invariants, Direction,                                            *ClonedPH, *LoopPH); +    if (MSSAU) { +      // Perform MSSA cloning updates. +      for (auto &VMap : VMaps) +        MSSAU->updateForClonedLoop(LBRPO, ExitBlocks, *VMap, +                                   /*IgnoreIncomingWithNoClones=*/true); +      MSSAU->updateExitBlocksForClonedLoop(ExitBlocks, VMaps, DT); +    }      DTUpdates.push_back({DominatorTree::Insert, SplitBB, ClonedPH});    }  | 

