/external/llvm/lib/Transforms/Utils/ |
D | BasicBlockUtils.cpp | 350 static void UpdatePHINodes(BasicBlock *OrigBB, BasicBlock *NewBB, in UpdatePHINodes() argument 355 for (BasicBlock::iterator I = OrigBB->begin(); isa<PHINode>(I); ) { in UpdatePHINodes() 474 void llvm::SplitLandingPadPredecessors(BasicBlock *OrigBB, in SplitLandingPadPredecessors() argument 480 assert(OrigBB->isLandingPad() && "Trying to split a non-landing pad!"); in SplitLandingPadPredecessors() 484 BasicBlock *NewBB1 = BasicBlock::Create(OrigBB->getContext(), in SplitLandingPadPredecessors() 485 OrigBB->getName() + Suffix1, in SplitLandingPadPredecessors() 486 OrigBB->getParent(), OrigBB); in SplitLandingPadPredecessors() 490 BranchInst *BI1 = BranchInst::Create(OrigBB, NewBB1); in SplitLandingPadPredecessors() 491 BI1->setDebugLoc(OrigBB->getFirstNonPHI()->getDebugLoc()); in SplitLandingPadPredecessors() 500 Preds[i]->getTerminator()->replaceUsesOfWith(OrigBB, NewBB1); in SplitLandingPadPredecessors() [all …]
|
D | InlineFunction.cpp | 1384 BasicBlock *OrigBB = TheCall->getParent(); in InlineFunction() local 1385 Function *Caller = OrigBB->getParent(); in InlineFunction() 1950 OrigBB->getInstList().splice(TheCall->getIterator(), in InlineFunction() 1999 OrigBB->splitBasicBlock(CreatedBranchToNormalDest->getIterator(), in InlineFunction() 2006 AfterCallBB = OrigBB->splitBasicBlock(TheCall->getIterator(), in InlineFunction() 2013 TerminatorInst *Br = OrigBB->getTerminator(); in InlineFunction() 2113 CalleeEntry->replaceAllUsesWith(OrigBB); // Update PHI nodes in InlineFunction() 2114 OrigBB->getInstList().splice(Br->getIterator(), CalleeEntry->getInstList()); in InlineFunction() 2117 OrigBB->getInstList().erase(Br); in InlineFunction()
|
D | LowerSwitch.cpp | 162 static void fixPhis(BasicBlock *SuccBB, BasicBlock *OrigBB, BasicBlock *NewBB, in fixPhis() argument 173 if (PN->getIncomingBlock(Idx) == OrigBB) { in fixPhis() 183 if (PN->getIncomingBlock(Idx) == OrigBB) { in fixPhis()
|
/external/llvm-project/llvm/lib/CodeGen/ |
D | BranchRelaxation.cpp | 223 MachineBasicBlock *OrigBB = MI.getParent(); in splitBlockBeforeInstr() local 227 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 228 MF->insert(++OrigBB->getIterator(), NewBB); in splitBlockBeforeInstr() 231 NewBB->splice(NewBB->end(), OrigBB, MI.getIterator(), OrigBB->end()); in splitBlockBeforeInstr() 237 TII->insertUnconditionalBranch(*OrigBB, NewBB, DebugLoc()); in splitBlockBeforeInstr() 242 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 243 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() 244 OrigBB->addSuccessor(DestBB); in splitBlockBeforeInstr() 248 OrigBB->updateTerminator(NewBB); in splitBlockBeforeInstr() 255 BlockInfo[OrigBB->getNumber()].Size = computeBlockSize(*OrigBB); in splitBlockBeforeInstr() [all …]
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/CodeGen/ |
D | BranchRelaxation.cpp | 228 MachineBasicBlock *OrigBB = MI.getParent(); in splitBlockBeforeInstr() local 232 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 233 MF->insert(++OrigBB->getIterator(), NewBB); in splitBlockBeforeInstr() 236 NewBB->splice(NewBB->end(), OrigBB, MI.getIterator(), OrigBB->end()); in splitBlockBeforeInstr() 242 TII->insertUnconditionalBranch(*OrigBB, NewBB, DebugLoc()); in splitBlockBeforeInstr() 247 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 248 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() 249 OrigBB->addSuccessor(DestBB); in splitBlockBeforeInstr() 254 OrigBB->updateTerminator(); in splitBlockBeforeInstr() 261 BlockInfo[OrigBB->getNumber()].Size = computeBlockSize(*OrigBB); in splitBlockBeforeInstr() [all …]
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Transforms/Utils/ |
D | BasicBlockUtils.cpp | 643 static void UpdatePHINodes(BasicBlock *OrigBB, BasicBlock *NewBB, in UpdatePHINodes() argument 648 for (BasicBlock::iterator I = OrigBB->begin(); isa<PHINode>(I); ) { in UpdatePHINodes() 778 void llvm::SplitLandingPadPredecessors(BasicBlock *OrigBB, in SplitLandingPadPredecessors() argument 785 assert(OrigBB->isLandingPad() && "Trying to split a non-landing pad!"); in SplitLandingPadPredecessors() 789 BasicBlock *NewBB1 = BasicBlock::Create(OrigBB->getContext(), in SplitLandingPadPredecessors() 790 OrigBB->getName() + Suffix1, in SplitLandingPadPredecessors() 791 OrigBB->getParent(), OrigBB); in SplitLandingPadPredecessors() 795 BranchInst *BI1 = BranchInst::Create(OrigBB, NewBB1); in SplitLandingPadPredecessors() 796 BI1->setDebugLoc(OrigBB->getFirstNonPHI()->getDebugLoc()); in SplitLandingPadPredecessors() 805 Preds[i]->getTerminator()->replaceUsesOfWith(OrigBB, NewBB1); in SplitLandingPadPredecessors() [all …]
|
D | LowerMemIntrinsics.cpp | 292 BasicBlock *OrigBB = InsertBefore->getParent(); in createMemMoveLoop() local 293 Function *F = OrigBB->getParent(); in createMemMoveLoop() 324 new ICmpInst(OrigBB->getTerminator(), ICmpInst::ICMP_EQ, CopyLen, in createMemMoveLoop() 372 BasicBlock *OrigBB = InsertBefore->getParent(); in createMemSetLoop() local 373 Function *F = OrigBB->getParent(); in createMemSetLoop() 375 OrigBB->splitBasicBlock(InsertBefore, "split"); in createMemSetLoop() 379 IRBuilder<> Builder(OrigBB->getTerminator()); in createMemSetLoop() 389 OrigBB->getTerminator()->eraseFromParent(); in createMemSetLoop() 393 LoopIndex->addIncoming(ConstantInt::get(TypeOfCopyLen, 0), OrigBB); in createMemSetLoop()
|
D | InlineFunction.cpp | 1479 auto *OrigBB = cast<BasicBlock>(Entry.first); in updateCallerBFI() local 1481 uint64_t Freq = CalleeBFI->getBlockFreq(OrigBB).getFrequency(); in updateCallerBFI() 1600 BasicBlock *OrigBB = TheCall->getParent(); in InlineFunction() local 1601 Function *Caller = OrigBB->getParent(); in InlineFunction() 1744 updateCallerBFI(OrigBB, VMap, IFI.CallerBFI, IFI.CalleeBFI, in InlineFunction() 2249 OrigBB->getInstList().splice(TheCall->getIterator(), in InlineFunction() 2298 OrigBB->splitBasicBlock(CreatedBranchToNormalDest->getIterator(), in InlineFunction() 2305 AfterCallBB = OrigBB->splitBasicBlock(TheCall->getIterator(), in InlineFunction() 2312 AfterCallBB, IFI.CallerBFI->getBlockFreq(OrigBB).getFrequency()); in InlineFunction() 2318 Instruction *Br = OrigBB->getTerminator(); in InlineFunction() [all …]
|
D | LowerSwitch.cpp | 211 fixPhis(BasicBlock *SuccBB, BasicBlock *OrigBB, BasicBlock *NewBB, in fixPhis() argument 222 if (PN->getIncomingBlock(Idx) == OrigBB) { in fixPhis() 232 if (PN->getIncomingBlock(Idx) == OrigBB) { in fixPhis()
|
/external/llvm/lib/Target/NVPTX/ |
D | NVPTXLowerAggrCopies.cpp | 66 BasicBlock *OrigBB = ConvertedInst->getParent(); in convertMemCpyToLoop() local 71 OrigBB->getTerminator()->setSuccessor(0, LoopBB); in convertMemCpyToLoop() 72 IRBuilder<> Builder(OrigBB->getTerminator()); in convertMemCpyToLoop() 85 LoopIndex->addIncoming(ConstantInt::get(TypeOfCopyLen, 0), OrigBB); in convertMemCpyToLoop() 136 BasicBlock *OrigBB = ConvertedInst->getParent(); in convertMemMoveToLoop() local 165 new ICmpInst(OrigBB->getTerminator(), ICmpInst::ICMP_EQ, CopyLen, in convertMemMoveToLoop() 211 BasicBlock *OrigBB = ConvertedInst->getParent(); in convertMemSetToLoop() local 216 OrigBB->getTerminator()->setSuccessor(0, LoopBB); in convertMemSetToLoop() 217 IRBuilder<> Builder(OrigBB->getTerminator()); in convertMemSetToLoop() 226 LoopIndex->addIncoming(ConstantInt::get(CopyLen->getType(), 0), OrigBB); in convertMemSetToLoop()
|
/external/llvm-project/llvm/lib/Transforms/Utils/ |
D | BasicBlockUtils.cpp | 664 static void UpdatePHINodes(BasicBlock *OrigBB, BasicBlock *NewBB, in UpdatePHINodes() argument 669 for (BasicBlock::iterator I = OrigBB->begin(); isa<PHINode>(I); ) { in UpdatePHINodes() 818 void llvm::SplitLandingPadPredecessors(BasicBlock *OrigBB, in SplitLandingPadPredecessors() argument 825 assert(OrigBB->isLandingPad() && "Trying to split a non-landing pad!"); in SplitLandingPadPredecessors() 829 BasicBlock *NewBB1 = BasicBlock::Create(OrigBB->getContext(), in SplitLandingPadPredecessors() 830 OrigBB->getName() + Suffix1, in SplitLandingPadPredecessors() 831 OrigBB->getParent(), OrigBB); in SplitLandingPadPredecessors() 835 BranchInst *BI1 = BranchInst::Create(OrigBB, NewBB1); in SplitLandingPadPredecessors() 836 BI1->setDebugLoc(OrigBB->getFirstNonPHI()->getDebugLoc()); in SplitLandingPadPredecessors() 845 Preds[i]->getTerminator()->replaceUsesOfWith(OrigBB, NewBB1); in SplitLandingPadPredecessors() [all …]
|
D | LowerMemIntrinsics.cpp | 296 BasicBlock *OrigBB = InsertBefore->getParent(); in createMemMoveLoop() local 297 Function *F = OrigBB->getParent(); in createMemMoveLoop() 333 new ICmpInst(OrigBB->getTerminator(), ICmpInst::ICMP_EQ, CopyLen, in createMemMoveLoop() 382 BasicBlock *OrigBB = InsertBefore->getParent(); in createMemSetLoop() local 383 Function *F = OrigBB->getParent(); in createMemSetLoop() 386 OrigBB->splitBasicBlock(InsertBefore, "split"); in createMemSetLoop() 390 IRBuilder<> Builder(OrigBB->getTerminator()); in createMemSetLoop() 400 OrigBB->getTerminator()->eraseFromParent(); in createMemSetLoop() 407 LoopIndex->addIncoming(ConstantInt::get(TypeOfCopyLen, 0), OrigBB); in createMemSetLoop()
|
D | InlineFunction.cpp | 1542 auto *OrigBB = cast<BasicBlock>(Entry.first); in updateCallerBFI() local 1544 uint64_t Freq = CalleeBFI->getBlockFreq(OrigBB).getFrequency(); in updateCallerBFI() 1660 BasicBlock *OrigBB = CB.getParent(); in InlineFunction() local 1661 Function *Caller = OrigBB->getParent(); in InlineFunction() 1811 updateCallerBFI(OrigBB, VMap, IFI.CallerBFI, IFI.CalleeBFI, in InlineFunction() 2304 OrigBB->getInstList().splice(CB.getIterator(), FirstNewBlock->getInstList(), in InlineFunction() 2352 OrigBB->splitBasicBlock(CreatedBranchToNormalDest->getIterator(), in InlineFunction() 2359 AfterCallBB = OrigBB->splitBasicBlock(CB.getIterator(), in InlineFunction() 2366 AfterCallBB, IFI.CallerBFI->getBlockFreq(OrigBB).getFrequency()); in InlineFunction() 2372 Instruction *Br = OrigBB->getTerminator(); in InlineFunction() [all …]
|
D | LowerSwitch.cpp | 120 BasicBlock *SuccBB, BasicBlock *OrigBB, BasicBlock *NewBB, in FixPhis() argument 131 if (PN->getIncomingBlock(Idx) == OrigBB) { in FixPhis() 141 if (PN->getIncomingBlock(Idx) == OrigBB) { in FixPhis()
|
/external/llvm/lib/Target/AArch64/ |
D | AArch64BranchRelaxation.cpp | 225 MachineBasicBlock *OrigBB = MI->getParent(); in splitBlockBeforeInstr() local 229 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 230 MF->insert(++OrigBB->getIterator(), NewBB); in splitBlockBeforeInstr() 233 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 239 BuildMI(OrigBB, DebugLoc(), TII->get(AArch64::B)).addMBB(NewBB); in splitBlockBeforeInstr() 249 computeBlockSize(*OrigBB); in splitBlockBeforeInstr() 256 adjustBlockOffsets(*OrigBB); in splitBlockBeforeInstr()
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/Mips/ |
D | MipsConstantIslandPass.cpp | 851 MachineBasicBlock *OrigBB = MI.getParent(); in splitBlockBeforeInstr() local 855 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 856 MachineFunction::iterator MBBI = ++OrigBB->getIterator(); in splitBlockBeforeInstr() 860 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 866 BuildMI(OrigBB, DebugLoc(), TII->get(Mips::Bimm16)).addMBB(NewBB); in splitBlockBeforeInstr() 870 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 873 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() 888 water_iterator IP = llvm::lower_bound(WaterList, OrigBB, CompareMBBNumbers); in splitBlockBeforeInstr() 890 if (WaterBB == OrigBB) in splitBlockBeforeInstr() 893 WaterList.insert(IP, OrigBB); in splitBlockBeforeInstr() [all …]
|
/external/llvm-project/llvm/lib/Target/Mips/ |
D | MipsConstantIslandPass.cpp | 845 MachineBasicBlock *OrigBB = MI.getParent(); in splitBlockBeforeInstr() local 849 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 850 MachineFunction::iterator MBBI = ++OrigBB->getIterator(); in splitBlockBeforeInstr() 854 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 860 BuildMI(OrigBB, DebugLoc(), TII->get(Mips::Bimm16)).addMBB(NewBB); in splitBlockBeforeInstr() 864 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 867 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() 882 water_iterator IP = llvm::lower_bound(WaterList, OrigBB, CompareMBBNumbers); in splitBlockBeforeInstr() 884 if (WaterBB == OrigBB) in splitBlockBeforeInstr() 887 WaterList.insert(IP, OrigBB); in splitBlockBeforeInstr() [all …]
|
/external/llvm/lib/Target/Mips/ |
D | MipsConstantIslandPass.cpp | 862 MachineBasicBlock *OrigBB = MI.getParent(); in splitBlockBeforeInstr() local 866 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 867 MachineFunction::iterator MBBI = ++OrigBB->getIterator(); in splitBlockBeforeInstr() 871 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 877 BuildMI(OrigBB, DebugLoc(), TII->get(Mips::Bimm16)).addMBB(NewBB); in splitBlockBeforeInstr() 881 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 884 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() 900 std::lower_bound(WaterList.begin(), WaterList.end(), OrigBB, in splitBlockBeforeInstr() 903 if (WaterBB == OrigBB) in splitBlockBeforeInstr() 906 WaterList.insert(IP, OrigBB); in splitBlockBeforeInstr() [all …]
|
/external/llvm-project/llvm/lib/Target/ARM/ |
D | ARMConstantIslandPass.cpp | 889 MachineBasicBlock *OrigBB = MI->getParent(); in splitBlockBeforeInstr() local 893 LRs.addLiveOuts(*OrigBB); in splitBlockBeforeInstr() 895 for (MachineInstr &LiveMI : make_range(OrigBB->rbegin(), LivenessEnd)) in splitBlockBeforeInstr() 900 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 901 MachineFunction::iterator MBBI = ++OrigBB->getIterator(); in splitBlockBeforeInstr() 905 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 913 BuildMI(OrigBB, DebugLoc(), TII->get(Opc)).addMBB(NewBB); in splitBlockBeforeInstr() 915 BuildMI(OrigBB, DebugLoc(), TII->get(Opc)) in splitBlockBeforeInstr() 921 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 924 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() [all …]
|
/external/llvm/lib/Transforms/Scalar/ |
D | PlaceSafepoints.cpp | 614 BasicBlock *OrigBB = InsertBefore->getParent(); in INITIALIZE_PASS_DEPENDENCY() local 633 if (Before == OrigBB->begin()) in INITIALIZE_PASS_DEPENDENCY() 639 assert(After != OrigBB->end() && "must have successor"); in INITIALIZE_PASS_DEPENDENCY() 655 BasicBlock::iterator Start = IsBegin ? OrigBB->begin() : std::next(Before); in INITIALIZE_PASS_DEPENDENCY()
|
/external/llvm-project/llvm/lib/Transforms/Scalar/ |
D | PlaceSafepoints.cpp | 625 BasicBlock *OrigBB = InsertBefore->getParent(); in INITIALIZE_PASS_DEPENDENCY() local 644 if (Before == OrigBB->begin()) in INITIALIZE_PASS_DEPENDENCY() 650 assert(After != OrigBB->end() && "must have successor"); in INITIALIZE_PASS_DEPENDENCY() 666 BasicBlock::iterator Start = IsBegin ? OrigBB->begin() : std::next(Before); in INITIALIZE_PASS_DEPENDENCY()
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Transforms/Scalar/ |
D | PlaceSafepoints.cpp | 624 BasicBlock *OrigBB = InsertBefore->getParent(); in INITIALIZE_PASS_DEPENDENCY() local 643 if (Before == OrigBB->begin()) in INITIALIZE_PASS_DEPENDENCY() 649 assert(After != OrigBB->end() && "must have successor"); in INITIALIZE_PASS_DEPENDENCY() 665 BasicBlock::iterator Start = IsBegin ? OrigBB->begin() : std::next(Before); in INITIALIZE_PASS_DEPENDENCY()
|
/external/llvm/lib/Transforms/Instrumentation/ |
D | IndirectCallPromotion.cpp | 381 BasicBlock *OrigBB, in fixupPHINodeForUnwind() argument 388 int IX = PHI->getBasicBlockIndex(OrigBB); in fixupPHINodeForUnwind() 403 BasicBlock *OrigBB, in fixupPHINodeForNormalDest() argument 410 int IX = PHI->getBasicBlockIndex(OrigBB); in fixupPHINodeForNormalDest() 416 PHI->addIncoming(NewInst, OrigBB); in fixupPHINodeForNormalDest()
|
/external/llvm/lib/Target/ARM/ |
D | ARMConstantIslandPass.cpp | 980 MachineBasicBlock *OrigBB = MI->getParent(); in splitBlockBeforeInstr() local 984 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 985 MachineFunction::iterator MBBI = ++OrigBB->getIterator(); in splitBlockBeforeInstr() 989 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 997 BuildMI(OrigBB, DebugLoc(), TII->get(Opc)).addMBB(NewBB); in splitBlockBeforeInstr() 999 BuildMI(OrigBB, DebugLoc(), TII->get(Opc)).addMBB(NewBB) in splitBlockBeforeInstr() 1004 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 1007 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() 1023 std::lower_bound(WaterList.begin(), WaterList.end(), OrigBB, in splitBlockBeforeInstr() 1026 if (WaterBB == OrigBB) in splitBlockBeforeInstr() [all …]
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/ARM/ |
D | ARMConstantIslandPass.cpp | 887 MachineBasicBlock *OrigBB = MI->getParent(); in splitBlockBeforeInstr() local 891 LRs.addLiveOuts(*OrigBB); in splitBlockBeforeInstr() 893 for (MachineInstr &LiveMI : make_range(OrigBB->rbegin(), LivenessEnd)) in splitBlockBeforeInstr() 898 MF->CreateMachineBasicBlock(OrigBB->getBasicBlock()); in splitBlockBeforeInstr() 899 MachineFunction::iterator MBBI = ++OrigBB->getIterator(); in splitBlockBeforeInstr() 903 NewBB->splice(NewBB->end(), OrigBB, MI, OrigBB->end()); in splitBlockBeforeInstr() 911 BuildMI(OrigBB, DebugLoc(), TII->get(Opc)).addMBB(NewBB); in splitBlockBeforeInstr() 913 BuildMI(OrigBB, DebugLoc(), TII->get(Opc)) in splitBlockBeforeInstr() 919 NewBB->transferSuccessors(OrigBB); in splitBlockBeforeInstr() 922 OrigBB->addSuccessor(NewBB); in splitBlockBeforeInstr() [all …]
|