Lines Matching refs:LoLoop

520     void ConvertVPTBlocks(LowOverheadLoop &LoLoop);
522 MachineInstr *ExpandLoopStart(LowOverheadLoop &LoLoop);
524 void Expand(LowOverheadLoop &LoLoop);
526 void IterationCountDCE(LowOverheadLoop &LoLoop);
1360 LowOverheadLoop LoLoop(*ML, *MLI, *RDA, *TRI, *TII); in ProcessLoop() local
1364 if (LoLoop.Preheader) in ProcessLoop()
1365 LoLoop.Start = SearchForStart(LoLoop.Preheader); in ProcessLoop()
1377 LoLoop.Dec = &MI; in ProcessLoop()
1379 LoLoop.End = &MI; in ProcessLoop()
1381 LoLoop.End = LoLoop.Dec = &MI; in ProcessLoop()
1383 LoLoop.Start = &MI; in ProcessLoop()
1388 LoLoop.Revert = true; in ProcessLoop()
1393 LoLoop.AnalyseMVEInst(&MI); in ProcessLoop()
1398 LLVM_DEBUG(LoLoop.dump()); in ProcessLoop()
1399 if (!LoLoop.FoundAllComponents()) { in ProcessLoop()
1404 assert(LoLoop.Start->getOpcode() != ARM::t2WhileLoopStart && in ProcessLoop()
1410 if (LoLoop.Dec != LoLoop.End) { in ProcessLoop()
1412 RDA->getReachingLocalUses(LoLoop.Dec, MCRegister::from(ARM::LR), Uses); in ProcessLoop()
1413 if (Uses.size() > 1 || !Uses.count(LoLoop.End)) { in ProcessLoop()
1415 LoLoop.Revert = true; in ProcessLoop()
1418 LoLoop.Validate(BBUtils.get()); in ProcessLoop()
1419 Expand(LoLoop); in ProcessLoop()
1524 void ARMLowOverheadLoops::IterationCountDCE(LowOverheadLoop &LoLoop) { in IterationCountDCE() argument
1525 if (!LoLoop.IsTailPredicationLegal()) in IterationCountDCE()
1530 MachineInstr *Def = RDA->getMIOperand(LoLoop.Start, 1); in IterationCountDCE()
1537 SmallPtrSet<MachineInstr*, 4> Killed = { LoLoop.Start, LoLoop.Dec, in IterationCountDCE()
1538 LoLoop.End }; in IterationCountDCE()
1539 if (!TryRemove(Def, *RDA, LoLoop.ToRemove, Killed)) in IterationCountDCE()
1543 MachineInstr* ARMLowOverheadLoops::ExpandLoopStart(LowOverheadLoop &LoLoop) { in ExpandLoopStart() argument
1547 IterationCountDCE(LoLoop); in ExpandLoopStart()
1549 MachineBasicBlock::iterator InsertPt = LoLoop.StartInsertPt; in ExpandLoopStart()
1550 MachineInstr *Start = LoLoop.Start; in ExpandLoopStart()
1551 MachineBasicBlock *MBB = LoLoop.StartInsertBB; in ExpandLoopStart()
1552 unsigned Opc = LoLoop.getStartOpcode(); in ExpandLoopStart()
1553 MachineOperand &Count = LoLoop.getLoopStartOperand(); in ExpandLoopStart()
1574 LoLoop.ToRemove.insert(Start); in ExpandLoopStart()
1578 void ARMLowOverheadLoops::ConvertVPTBlocks(LowOverheadLoop &LoLoop) { in ConvertVPTBlocks() argument
1591 for (auto &Block : LoLoop.getVPTBlocks()) { in ConvertVPTBlocks()
1608 LoLoop.BlockMasksToRecompute.insert(MIB.getInstr()); in ConvertVPTBlocks()
1609 LoLoop.ToRemove.insert(TheVCMP); in ConvertVPTBlocks()
1662 LoLoop.BlockMasksToRecompute.insert(MIB.getInstr()); in ConvertVPTBlocks()
1671 LoLoop.ToRemove.insert(VPST); in ConvertVPTBlocks()
1679 LoLoop.ToRemove.insert(VPST); in ConvertVPTBlocks()
1681 LoLoop.BlockMasksToRecompute.insert(VPST); in ConvertVPTBlocks()
1693 !LoLoop.ToRemove.contains(VprDef)) { in ConvertVPTBlocks()
1706 LoLoop.ToRemove.insert(VPST); in ConvertVPTBlocks()
1712 LoLoop.ToRemove.insert(LoLoop.VCTPs.begin(), LoLoop.VCTPs.end()); in ConvertVPTBlocks()
1715 void ARMLowOverheadLoops::Expand(LowOverheadLoop &LoLoop) { in Expand() argument
1718 auto ExpandLoopEnd = [this](LowOverheadLoop &LoLoop) { in Expand() argument
1719 MachineInstr *End = LoLoop.End; in Expand()
1721 unsigned Opc = LoLoop.IsTailPredicationLegal() ? in Expand()
1726 unsigned Off = LoLoop.Dec == LoLoop.End ? 1 : 0; in Expand()
1730 LoLoop.ToRemove.insert(LoLoop.Dec); in Expand()
1731 LoLoop.ToRemove.insert(End); in Expand()
1777 if (LoLoop.Revert) { in Expand()
1778 if (isWhileLoopStart(*LoLoop.Start)) in Expand()
1779 RevertWhile(LoLoop.Start); in Expand()
1781 RevertDo(LoLoop.Start); in Expand()
1782 if (LoLoop.Dec == LoLoop.End) in Expand()
1783 RevertLoopEndDec(LoLoop.End); in Expand()
1785 RevertLoopEnd(LoLoop.End, RevertLoopDec(LoLoop.Dec)); in Expand()
1787 ExpandVMOVCopies(LoLoop.VMOVCopies); in Expand()
1788 LoLoop.Start = ExpandLoopStart(LoLoop); in Expand()
1789 if (LoLoop.Start) in Expand()
1790 RemoveDeadBranch(LoLoop.Start); in Expand()
1791 LoLoop.End = ExpandLoopEnd(LoLoop); in Expand()
1792 RemoveDeadBranch(LoLoop.End); in Expand()
1793 if (LoLoop.IsTailPredicationLegal()) in Expand()
1794 ConvertVPTBlocks(LoLoop); in Expand()
1795 for (auto *I : LoLoop.ToRemove) { in Expand()
1799 for (auto *I : LoLoop.BlockMasksToRecompute) { in Expand()
1806 PostOrderLoopTraversal DFS(LoLoop.ML, *MLI); in Expand()