Home
last modified time | relevance | path

Searched refs:TBB (Results 1 – 25 of 74) sorted by relevance

123

/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/CodeGen/
DEarlyIfConversion.cpp95 MachineBasicBlock *TBB; member in __anon1fac302f0111::SSAIfConv
102 bool isTriangle() const { return TBB == Tail || FBB == Tail; } in isTriangle()
105 MachineBasicBlock *getTPred() const { return TBB == Tail ? Head : TBB; } in getTPred()
434 TBB = FBB = Tail = nullptr; in canConvertIf()
482 if (TII->analyzeBranch(*Head, TBB, FBB, Cond)) { in canConvertIf()
488 if (!TBB) { in canConvertIf()
502 FBB = TBB == Succ0 ? Succ1 : Succ0; in canConvertIf()
534 if (TBB != Tail && !canPredicateInstrs(TBB)) in canConvertIf()
539 if (TBB != Tail && !canSpeculateInstrs(TBB)) in canConvertIf()
626 assert(Head && Tail && TBB && FBB && "Call canConvertIf first."); in convertIf()
[all …]
DBranchRelaxation.cpp304 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in fixupConditionalBranch() local
315 auto insertBranch = [&](MachineBasicBlock *MBB, MachineBasicBlock *TBB, in fixupConditionalBranch()
320 TII->insertBranch(*MBB, TBB, FBB, Cond, DL, &NewBrSize); in fixupConditionalBranch()
340 bool Fail = TII->analyzeBranch(*MBB, TBB, FBB, Cond); in fixupConditionalBranch()
367 insertBranch(MBB, FBB, TBB, Cond); in fixupConditionalBranch()
387 LLVM_DEBUG(dbgs() << " Insert B to " << printMBBReference(*TBB) in fixupConditionalBranch()
393 insertBranch(MBB, &NextBB, TBB, Cond); in fixupConditionalBranch()
418 insertUncondBranch(NewBB, TBB); in fixupConditionalBranch()
425 << printMBBReference(*TBB) << ".\n"); in fixupConditionalBranch()
428 MBB->replaceSuccessor(TBB, NewBB); in fixupConditionalBranch()
[all …]
DMachineBasicBlock.cpp538 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in updateTerminator() local
541 bool B = TII->analyzeBranch(*this, TBB, FBB, Cond); in updateTerminator()
545 if (TBB) { in updateTerminator()
548 if (isLayoutSuccessor(TBB)) in updateTerminator()
557 assert(!TBB && "Found more than one non-landing-pad successor!"); in updateTerminator()
558 TBB = *SI; in updateTerminator()
563 if (!TBB) in updateTerminator()
568 if (!isLayoutSuccessor(TBB)) in updateTerminator()
569 TII->insertBranch(*this, TBB, nullptr, Cond, DL); in updateTerminator()
578 if (isLayoutSuccessor(TBB)) { in updateTerminator()
[all …]
DBranchFolding.cpp207 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in OptimizeFunction() local
209 if (!TII->analyzeBranch(MBB, TBB, FBB, Cond, true)) in OptimizeFunction()
210 MadeChange |= MBB.CorrectExtraCFGEdges(TBB, FBB, !Cond.empty()); in OptimizeFunction()
468 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in FixTail() local
471 if (I != MF->end() && !TII->analyzeBranch(*CurMBB, TBB, FBB, Cond, true)) { in FixTail()
473 if (TBB == NextBB && !Cond.empty() && !FBB) { in FixTail()
1138 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in TailMergeBlocks() local
1140 if (!TII->analyzeBranch(*PBB, TBB, FBB, Cond, true)) { in TailMergeBlocks()
1144 if (!Cond.empty() && TBB == IBB) { in TailMergeBlocks()
1156 if (TBB && (Cond.empty() || FBB)) { in TailMergeBlocks()
[all …]
DMachineLoopUtils.cpp120 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in PeelSingleBlockLoop() local
122 bool CanAnalyzeBr = !TII->analyzeBranch(*Loop, TBB, FBB, Cond); in PeelSingleBlockLoop()
126 TII->insertBranch(*Loop, TBB == Exit ? NewBB : TBB, in PeelSingleBlockLoop()
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/NVPTX/
DNVPTXInstrInfo.cpp96 MachineBasicBlock *&TBB, in analyzeBranch() argument
111 TBB = LastInst.getOperand(0).getMBB(); in analyzeBranch()
115 TBB = LastInst.getOperand(1).getMBB(); in analyzeBranch()
133 TBB = SecondLastInst.getOperand(1).getMBB(); in analyzeBranch()
143 TBB = SecondLastInst.getOperand(0).getMBB(); in analyzeBranch()
181 MachineBasicBlock *TBB, in insertBranch() argument
189 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
196 BuildMI(&MBB, DL, get(NVPTX::GOTO)).addMBB(TBB); in insertBranch()
199 .addMBB(TBB); in insertBranch()
204 BuildMI(&MBB, DL, get(NVPTX::CBranch)).addReg(Cond[0].getReg()).addMBB(TBB); in insertBranch()
DNVPTXInstrInfo.h56 bool analyzeBranch(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
62 unsigned insertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/WebAssembly/
DWebAssemblyInstrInfo.cpp103 MachineBasicBlock *&TBB, in analyzeBranch() argument
125 TBB = MI.getOperand(0).getMBB(); in analyzeBranch()
133 TBB = MI.getOperand(0).getMBB(); in analyzeBranch()
138 TBB = MI.getOperand(0).getMBB(); in analyzeBranch()
147 TBB = MI.getOperand(0).getMBB(); in analyzeBranch()
181 MachineBasicBlock &MBB, MachineBasicBlock *TBB, MachineBasicBlock *FBB, in insertBranch() argument
186 if (!TBB) in insertBranch()
189 BuildMI(&MBB, DL, get(WebAssembly::BR)).addMBB(TBB); in insertBranch()
204 .addMBB(TBB) in insertBranch()
208 BuildMI(&MBB, DL, get(WebAssembly::BR_IF)).addMBB(TBB).add(Cond[1]); in insertBranch()
[all …]
DWebAssemblyInstrInfo.h56 bool analyzeBranch(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
62 unsigned insertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/MSP430/
DMSP430InstrInfo.cpp176 MachineBasicBlock *&TBB, in analyzeBranch() argument
206 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
218 TBB = nullptr; in analyzeBranch()
225 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
238 FBB = TBB; in analyzeBranch()
239 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
247 assert(TBB); in analyzeBranch()
251 if (TBB != I->getOperand(0).getMBB()) in analyzeBranch()
266 MachineBasicBlock *TBB, in insertBranch() argument
272 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/X86/
DX86CondBrFolding.cpp89 MachineBasicBlock *TBB; member
150 assert(SaveMBB == PredMBBInfo->TBB || SaveMBB == PredMBBInfo->FBB); in findPath()
222 if (MBBInfo->TBB == OrigDest) { in replaceBrDest()
227 MBBInfo->TBB = NewDest; in replaceBrDest()
253 .addMBB(MBBInfo->TBB).addImm(CC); in fixupModifiedCond()
284 MachineBasicBlock *TargetMBB = MBBInfo->TBB; in optimizeCondBr()
285 BranchProbability TargetProb = MBPI->getEdgeProbability(&MBB, MBBInfo->TBB); in optimizeCondBr()
332 replaceBrDest(RootMBB, RootMBBInfo->TBB, TargetMBB); in optimizeCondBr()
480 MachineBasicBlock *TBB; in analyzeMBB() local
494 FBB = TBB = nullptr; in analyzeMBB()
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/AVR/
DAVRInstrInfo.cpp264 MachineBasicBlock *&TBB, in analyzeBranch() argument
297 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
311 TBB = 0; in analyzeBranch()
319 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
369 FBB = TBB; in analyzeBranch()
370 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
378 assert(TBB); in analyzeBranch()
382 if (TBB != I->getOperand(0).getMBB()) { in analyzeBranch()
399 MachineBasicBlock *TBB, in insertBranch() argument
407 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/XCore/
DXCoreInstrInfo.cpp190 MachineBasicBlock *&TBB, in analyzeBranch() argument
208 TBB = LastInst->getOperand(0).getMBB(); in analyzeBranch()
219 TBB = LastInst->getOperand(1).getMBB(); in analyzeBranch()
240 TBB = SecondLastInst->getOperand(1).getMBB(); in analyzeBranch()
252 TBB = SecondLastInst->getOperand(0).getMBB(); in analyzeBranch()
272 MachineBasicBlock *TBB, in insertBranch() argument
278 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
286 BuildMI(&MBB, DL, get(XCore::BRFU_lu6)).addMBB(TBB); in insertBranch()
291 .addMBB(TBB); in insertBranch()
300 .addMBB(TBB); in insertBranch()
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/Mips/
DMipsInstrInfo.cpp95 MachineBasicBlock *&TBB, in analyzeBranch() argument
100 BranchType BT = analyzeBranch(MBB, TBB, FBB, Cond, AllowModify, BranchInstrs); in analyzeBranch()
105 void MipsInstrInfo::BuildCondBr(MachineBasicBlock &MBB, MachineBasicBlock *TBB, in BuildCondBr() argument
117 MIB.addMBB(TBB); in BuildCondBr()
121 MachineBasicBlock *TBB, in insertBranch() argument
127 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
140 BuildCondBr(MBB, TBB, DL, Cond); in insertBranch()
148 BuildMI(&MBB, DL, get(UncondBrOpc)).addMBB(TBB); in insertBranch()
150 BuildCondBr(MBB, TBB, DL, Cond); in insertBranch()
191 MachineBasicBlock &MBB, MachineBasicBlock *&TBB, MachineBasicBlock *&FBB, in analyzeBranch() argument
[all …]
DMipsInstrInfo.h63 bool analyzeBranch(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
71 unsigned insertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
79 BranchType analyzeBranch(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
177 void BuildCondBr(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/ARC/
DARCInstrInfo.cpp171 MachineBasicBlock *&TBB, in analyzeBranch() argument
175 TBB = FBB = nullptr; in analyzeBranch()
199 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
206 FBB = TBB; in analyzeBranch()
207 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
371 MachineBasicBlock *TBB, in insertBranch() argument
378 assert(TBB && "InsertBranch must not be told to insert a fallthrough"); in insertBranch()
383 BuildMI(&MBB, dl, get(ARC::BR)).addMBB(TBB); in insertBranch()
388 MIB.addMBB(TBB); in insertBranch()
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/BPF/
DBPFInstrInfo.cpp165 MachineBasicBlock *&TBB, in analyzeBranch() argument
190 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
202 TBB = nullptr; in analyzeBranch()
209 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
220 MachineBasicBlock *TBB, in insertBranch() argument
228 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
233 BuildMI(&MBB, DL, get(BPF::JMP)).addMBB(TBB); in insertBranch()
DBPFInstrInfo.h48 bool analyzeBranch(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
55 unsigned insertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/Hexagon/
DHexagonBranchRelaxation.cpp161 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in isJumpOutOfRange() local
165 if (HII->analyzeBranch(B, TBB, FBB, Cond, false)) { in isJumpOutOfRange()
170 TBB = FirstTerm->getOperand(HII->getCExtOpNum(*FirstTerm)).getMBB(); in isJumpOutOfRange()
172 if (TBB && &MI == &*FirstTerm) { in isJumpOutOfRange()
173 Distance = std::abs((long long)InstOffset - BlockToInstOffset[TBB]) in isJumpOutOfRange()
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/Sparc/
DSparcInstrInfo.cpp160 MachineBasicBlock *&TBB, in analyzeBranch() argument
178 TBB = LastInst->getOperand(0).getMBB(); in analyzeBranch()
183 parseCondBranch(LastInst, TBB, Cond); in analyzeBranch()
202 TBB = LastInst->getOperand(0).getMBB(); in analyzeBranch()
217 parseCondBranch(SecondLastInst, TBB, Cond); in analyzeBranch()
225 TBB = SecondLastInst->getOperand(0).getMBB(); in analyzeBranch()
243 MachineBasicBlock *TBB, in insertBranch() argument
248 assert(TBB && "insertBranch must not be told to insert a fallthrough"); in insertBranch()
255 BuildMI(&MBB, DL, get(SP::BA)).addMBB(TBB); in insertBranch()
263 BuildMI(&MBB, DL, get(SP::BCOND)).addMBB(TBB).addImm(CC); in insertBranch()
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/AArch64/
DAArch64ConditionOptimizer.cpp350 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in runOnMachineFunction() local
351 if (TII->analyzeBranch(*HBB, TBB, FBB, HeadCond)) { in runOnMachineFunction()
356 if (!TBB || TBB == HBB) { in runOnMachineFunction()
362 if (TII->analyzeBranch(*TBB, TBB_TBB, TBB_FBB, TrueCond)) { in runOnMachineFunction()
371 MachineInstr *TrueCmpMI = findSuitableCompare(TBB); in runOnMachineFunction()
DAArch64SpeculationHardening.cpp152 bool endsWithCondControlFlow(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
187 MachineBasicBlock &MBB, MachineBasicBlock *&TBB, MachineBasicBlock *&FBB, in endsWithCondControlFlow() argument
190 if (TII->analyzeBranch(MBB, TBB, FBB, analyzeBranchCondCode, false)) in endsWithCondControlFlow()
200 assert(TBB != nullptr); in endsWithCondControlFlow()
207 if (TBB == FBB) in endsWithCondControlFlow()
245 MachineBasicBlock *TBB = nullptr; in instrumentControlFlow() local
249 if (!endsWithCondControlFlow(MBB, TBB, FBB, CondCode)) { in instrumentControlFlow()
258 MachineBasicBlock *SplitEdgeTBB = MBB.SplitCriticalEdge(TBB, *this); in instrumentControlFlow()
DAArch64ConditionalCompares.cpp501 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in canConvert() local
502 if (TII->analyzeBranch(*Head, TBB, FBB, HeadCond)) { in canConvert()
510 if (!TBB || HeadCond.empty()) { in canConvert()
524 if (TBB != CmpBB) { in canConvert()
525 assert(TBB == Tail && "Unexpected TBB"); in canConvert()
530 TBB = FBB = nullptr; in canConvert()
531 if (TII->analyzeBranch(*CmpBB, TBB, FBB, CmpBBCond)) { in canConvert()
537 if (!TBB || CmpBBCond.empty()) { in canConvert()
550 if (TBB != Tail) in canConvert()
DAArch64A53Fix835769.cpp139 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in getBBFallenThrough() local
144 if (S == PrevBB && !TII->analyzeBranch(*PrevBB, TBB, FBB, Cond) && !TBB && in getBBFallenThrough()
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Target/RISCV/
DRISCVInstrInfo.cpp237 MachineBasicBlock *&TBB, in analyzeBranch() argument
241 TBB = FBB = nullptr; in analyzeBranch()
282 TBB = I->getOperand(0).getMBB(); in analyzeBranch()
288 parseCondBranch(*I, TBB, Cond); in analyzeBranch()
295 parseCondBranch(*std::prev(I), TBB, Cond); in analyzeBranch()
339 MachineBasicBlock &MBB, MachineBasicBlock *TBB, MachineBasicBlock *FBB, in insertBranch() argument
345 assert(TBB && "InsertBranch must not be told to insert a fallthrough"); in insertBranch()
351 MachineInstr &MI = *BuildMI(&MBB, DL, get(RISCV::PseudoBR)).addMBB(TBB); in insertBranch()
360 *BuildMI(&MBB, DL, get(Opc)).add(Cond[1]).add(Cond[2]).addMBB(TBB); in insertBranch()

123