Home
last modified time | relevance | path

Searched refs:BB (Results 1 – 25 of 2772) sorted by relevance

12345678910>>...111

/external/llvm/test/CodeGen/X86/
Dswitch-edge-weight.ll34 ; CHECK: BB#0:
35 ; BB#0 to BB#4: [0, 1133] (65 = 60 + 5)
36 ; BB#0 to BB#5: [1134, UINT32_MAX] (25 = 20 + 5)
37 ; CHECK: Successors according to CFG: BB#4({{[0-9a-fx/= ]+}}72.22%) BB#5({{[0-9a-fx/= ]+}}27.78%)
39 ; CHECK: BB#4:
40 ; BB#4 to BB#1: [155, 159] (50)
41 ; BB#4 to BB#5: [0, 1133] - [155, 159] (15 = 10 + 5)
42 ; CHECK: Successors according to CFG: BB#1({{[0-9a-fx/= ]+}}76.92%) BB#7({{[0-9a-fx/= ]+}}23.08%)
44 ; CHECK: BB#5:
45 ; BB#5 to BB#1: {1140} (10)
[all …]
/external/swiftshader/third_party/LLVM/include/llvm/Analysis/
DBlockFrequencyImpl.h54 std::string getBlockName(BasicBlock *BB) const { in getBlockName() argument
55 return BB->getNameStr(); in getBlockName()
62 if (const BasicBlock *BB = MBB->getBasicBlock()) in getBlockName() local
63 ss << " derived from LLVM BB " << BB->getNameStr(); in getBlockName()
68 void setBlockFreq(BlockT *BB, BlockFrequency Freq) { in setBlockFreq() argument
69 Freqs[BB] = Freq; in setBlockFreq()
70 DEBUG(dbgs() << "Frequency(" << getBlockName(BB) << ") = " << Freq << "\n"); in setBlockFreq()
82 void incBlockFreq(BlockT *BB, BlockFrequency Freq) { in incBlockFreq() argument
83 Freqs[BB] += Freq; in incBlockFreq()
84 DEBUG(dbgs() << "Frequency(" << getBlockName(BB) << ") += " << Freq in incBlockFreq()
[all …]
/external/llvm/lib/CodeGen/
DIfConversion.cpp124 MachineBasicBlock *BB; member
133 ExtraCost(0), ExtraCost2(0), BB(nullptr), TrueBB(nullptr), in BBInfo()
213 void InvalidatePreds(MachineBasicBlock *BB);
228 bool MeetIfcvtSizeLimit(MachineBasicBlock &BB, in MeetIfcvtSizeLimit() argument
231 return Cycle > 0 && TII->isProfitableToIfCvt(BB, Cycle, Extra, in MeetIfcvtSizeLimit()
268 return C1->BBI.BB->getNumber() < C2->BBI.BB->getNumber(); in IfcvtTokenCmp()
357 << "): BB#" << BBI.BB->getNumber() << " (" in INITIALIZE_PASS_DEPENDENCY()
384 DEBUG(dbgs() << "): BB#" << BBI.BB->getNumber() << " (T:" in INITIALIZE_PASS_DEPENDENCY()
402 DEBUG(dbgs() << "Ifcvt (Diamond): BB#" << BBI.BB->getNumber() << " (T:" in INITIALIZE_PASS_DEPENDENCY()
440 static MachineBasicBlock *findFalseBlock(MachineBasicBlock *BB, in findFalseBlock() argument
[all …]
DMachineSSAUpdater.cpp63 bool MachineSSAUpdater::HasValueForBlock(MachineBasicBlock *BB) const { in HasValueForBlock()
64 return getAvailableVals(AV).count(BB); in HasValueForBlock()
69 void MachineSSAUpdater::AddAvailableValue(MachineBasicBlock *BB, unsigned V) { in AddAvailableValue() argument
70 getAvailableVals(AV)[BB] = V; in AddAvailableValue()
75 unsigned MachineSSAUpdater::GetValueAtEndOfBlock(MachineBasicBlock *BB) { in GetValueAtEndOfBlock() argument
76 return GetValueAtEndOfBlockInternal(BB); in GetValueAtEndOfBlock()
80 unsigned LookForIdenticalPHI(MachineBasicBlock *BB, in LookForIdenticalPHI() argument
82 if (BB->empty()) in LookForIdenticalPHI()
85 MachineBasicBlock::iterator I = BB->begin(); in LookForIdenticalPHI()
92 while (I != BB->end() && I->isPHI()) { in LookForIdenticalPHI()
[all …]
/external/llvm/lib/Target/Mips/
DMips16ISelLowering.cpp169 MachineBasicBlock *BB) const { in EmitInstrWithCustomInserter()
172 return MipsTargetLowering::EmitInstrWithCustomInserter(MI, BB); in EmitInstrWithCustomInserter()
174 return emitSel16(Mips::BeqzRxImm16, MI, BB); in EmitInstrWithCustomInserter()
176 return emitSel16(Mips::BnezRxImm16, MI, BB); in EmitInstrWithCustomInserter()
178 return emitSeliT16(Mips::Bteqz16, Mips::CmpiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
180 return emitSeliT16(Mips::Bteqz16, Mips::SltiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
182 return emitSeliT16(Mips::Bteqz16, Mips::SltiuRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
184 return emitSeliT16(Mips::Btnez16, Mips::CmpiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
186 return emitSeliT16(Mips::Btnez16, Mips::SltiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
188 return emitSeliT16(Mips::Btnez16, Mips::SltiuRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
[all …]
/external/swiftshader/third_party/llvm-7.0/llvm/lib/Target/Mips/
DMips16ISelLowering.cpp169 MachineBasicBlock *BB) const { in EmitInstrWithCustomInserter()
172 return MipsTargetLowering::EmitInstrWithCustomInserter(MI, BB); in EmitInstrWithCustomInserter()
174 return emitSel16(Mips::BeqzRxImm16, MI, BB); in EmitInstrWithCustomInserter()
176 return emitSel16(Mips::BnezRxImm16, MI, BB); in EmitInstrWithCustomInserter()
178 return emitSeliT16(Mips::Bteqz16, Mips::CmpiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
180 return emitSeliT16(Mips::Bteqz16, Mips::SltiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
182 return emitSeliT16(Mips::Bteqz16, Mips::SltiuRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
184 return emitSeliT16(Mips::Btnez16, Mips::CmpiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
186 return emitSeliT16(Mips::Btnez16, Mips::SltiRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
188 return emitSeliT16(Mips::Btnez16, Mips::SltiuRxImmX16, MI, BB); in EmitInstrWithCustomInserter()
[all …]
/external/swiftshader/third_party/SPIRV-Tools/source/
Dcfa.h31 template <class BB>
33 using bb_ptr = BB*;
34 using cbb_ptr = const BB*;
35 using bb_iter = typename std::vector<BB*>::const_iterator;
36 using get_blocks_func = std::function<const std::vector<BB*>*(const BB*)>;
76 const BB* entry, get_blocks_func successor_func,
106 static std::vector<std::pair<BB*, BB*>> CalculateDominators(
114 static std::vector<BB*> TraversalRoots(const std::vector<BB*>& blocks,
119 std::vector<BB*>& ordered_blocks, BB* pseudo_entry_block,
120 BB* pseudo_exit_block,
[all …]
/external/deqp-deps/SPIRV-Tools/source/
Dcfa.h31 template <class BB>
33 using bb_ptr = BB*;
34 using cbb_ptr = const BB*;
35 using bb_iter = typename std::vector<BB*>::const_iterator;
36 using get_blocks_func = std::function<const std::vector<BB*>*(const BB*)>;
76 const BB* entry, get_blocks_func successor_func,
106 static std::vector<std::pair<BB*, BB*>> CalculateDominators(
114 static std::vector<BB*> TraversalRoots(const std::vector<BB*>& blocks,
119 std::vector<BB*>& ordered_blocks, BB* pseudo_entry_block,
120 BB* pseudo_exit_block,
[all …]
/external/swiftshader/third_party/llvm-7.0/llvm/lib/Transforms/Scalar/
DJumpThreading.cpp203 static void updatePredecessorProfileMetadata(PHINode *PN, BasicBlock *BB) { in updatePredecessorProfileMetadata() argument
204 BranchInst *CondBr = dyn_cast<BranchInst>(BB->getTerminator()); in updatePredecessorProfileMetadata()
244 auto PredOutEdge = GetPredOutEdge(PN->getIncomingBlock(i), BB); in updatePredecessorProfileMetadata()
364 for (auto &BB : F) in runImpl() local
365 if (!DT.isReachableFromEntry(&BB)) in runImpl()
366 Unreachable.insert(&BB); in runImpl()
374 for (auto &BB : F) { in runImpl() local
375 if (Unreachable.count(&BB)) in runImpl()
377 while (ProcessBlock(&BB)) // Thread all of the branches we can over BB. in runImpl()
382 if (&BB == &F.getEntryBlock() || DDT->pendingDeletedBB(&BB)) in runImpl()
[all …]
DADCE.cpp102 BasicBlock *BB = nullptr; member
124 bool isLive(BasicBlock *BB) { return BlockInfo[BB].Live; } in isLive() argument
162 void markLive(BlockInfoType &BB);
163 void markLive(BasicBlock *BB) { markLive(BlockInfo[BB]); } in markLive() argument
190 void makeUnconditional(BasicBlock *BB, BasicBlock *Target);
223 for (auto &BB : F) { in initialize() local
224 NumInsts += BB.size(); in initialize()
225 auto &Info = BlockInfo[&BB]; in initialize()
226 Info.BB = &BB; in initialize()
227 Info.Terminator = BB.getTerminator(); in initialize()
[all …]
/external/swiftshader/third_party/LLVM/lib/Transforms/Scalar/
DJumpThreading.cpp113 bool ProcessBlock(BasicBlock *BB);
114 bool ThreadEdge(BasicBlock *BB, const SmallVectorImpl<BasicBlock*> &PredBBs,
116 bool DuplicateCondBranchOnPHIIntoPred(BasicBlock *BB,
119 bool ComputeValueKnownInPredecessors(Value *V, BasicBlock *BB,
122 bool ProcessThreadableEdges(Value *Cond, BasicBlock *BB,
155 BasicBlock *BB = I; in runOnFunction() local
157 while (ProcessBlock(BB)) in runOnFunction()
164 if (pred_begin(BB) == pred_end(BB) && in runOnFunction()
165 BB != &BB->getParent()->getEntryBlock()) { in runOnFunction()
166 DEBUG(dbgs() << " JT: Deleting dead block '" << BB->getName() in runOnFunction()
[all …]
DSimplifyCFGPass.cpp65 BasicBlock *BB = I->getParent(); in ChangeToUnreachable() local
68 for (succ_iterator SI = succ_begin(BB), SE = succ_end(BB); SI != SE; ++SI) in ChangeToUnreachable()
69 (*SI)->removePredecessor(BB); in ChangeToUnreachable()
75 Intrinsic::getDeclaration(BB->getParent()->getParent(), Intrinsic::trap); in ChangeToUnreachable()
82 BasicBlock::iterator BBI = I, BBE = BB->end(); in ChangeToUnreachable()
86 BB->getInstList().erase(BBI++); in ChangeToUnreachable()
92 BasicBlock *BB = II->getParent(); in ChangeToCall() local
105 II->getUnwindDest()->removePredecessor(BB); in ChangeToCall()
106 BB->getInstList().erase(II); in ChangeToCall()
109 static bool MarkAliveBlocks(BasicBlock *BB, in MarkAliveBlocks() argument
[all …]
/external/swiftshader/third_party/llvm-7.0/llvm/include/llvm/IR/
DCFG.h99 inline pred_iterator pred_begin(BasicBlock *BB) { return pred_iterator(BB); } in pred_begin() argument
100 inline const_pred_iterator pred_begin(const BasicBlock *BB) { in pred_begin() argument
101 return const_pred_iterator(BB); in pred_begin()
103 inline pred_iterator pred_end(BasicBlock *BB) { return pred_iterator(BB, true);} in pred_end() argument
104 inline const_pred_iterator pred_end(const BasicBlock *BB) { in pred_end() argument
105 return const_pred_iterator(BB, true); in pred_end()
107 inline bool pred_empty(const BasicBlock *BB) { in pred_empty() argument
108 return pred_begin(BB) == pred_end(BB); in pred_empty()
110 inline unsigned pred_size(const BasicBlock *BB) { in pred_size() argument
111 return std::distance(pred_begin(BB), pred_end(BB)); in pred_size()
[all …]
/external/swiftshader/third_party/LLVM/lib/Analysis/
DProfileInfo.cpp60 ProfileInfoT<Function,BasicBlock>::getExecutionCount(const BasicBlock *BB) { in getExecutionCount() argument
62 BlockInformation.find(BB->getParent()); in getExecutionCount()
64 BlockCounts::iterator I = J->second.find(BB); in getExecutionCount()
71 const_pred_iterator PI = pred_begin(BB), PE = pred_end(BB); in getExecutionCount()
75 Edge e = getEdge(0, BB); in getExecutionCount()
85 double w = getEdgeWeight(getEdge(P, BB)); in getExecutionCount()
98 succ_const_iterator SI = succ_begin(BB), SE = succ_end(BB); in getExecutionCount()
102 Edge e = getEdge(BB,0); in getExecutionCount()
109 double w = getEdgeWeight(getEdge(BB, *SI)); in getExecutionCount()
119 if (Count != MissingValue) BlockInformation[BB->getParent()][BB] = Count; in getExecutionCount()
[all …]
DBranchProbabilityInfo.cpp89 static bool isReturningBlock(BasicBlock *BB) { in isReturningBlock() argument
93 TerminatorInst *TI = BB->getTerminator(); in isReturningBlock()
104 Visited.insert(BB); in isReturningBlock()
105 BB = TI->getSuccessor(0); in isReturningBlock()
108 if (Visited.count(BB)) in isReturningBlock()
115 uint32_t getMaxWeightFor(BasicBlock *BB) const { in getMaxWeightFor()
116 return UINT32_MAX / BB->getTerminator()->getNumSuccessors(); in getMaxWeightFor()
126 bool calcMetadataWeights(BasicBlock *BB);
129 bool calcReturnHeuristics(BasicBlock *BB);
132 bool calcPointerHeuristics(BasicBlock *BB);
[all …]
/external/swiftshader/third_party/LLVM/lib/CodeGen/
DIfConversion.cpp115 MachineBasicBlock *BB; member
124 ExtraCost(0), ExtraCost2(0), BB(0), TrueBB(0), FalseBB(0) {} in BBInfo()
184 BBInfo &AnalyzeBlock(MachineBasicBlock *BB,
189 void InvalidatePreds(MachineBasicBlock *BB);
205 bool MeetIfcvtSizeLimit(MachineBasicBlock &BB, in MeetIfcvtSizeLimit() argument
208 return Cycle > 0 && TII->isProfitableToIfCvt(BB, Cycle, Extra, in MeetIfcvtSizeLimit()
244 return C1->BBI.BB->getNumber() < C2->BBI.BB->getNumber(); in IfcvtTokenCmp()
324 << "): BB#" << BBI.BB->getNumber() << " (" in runOnMachineFunction()
351 DEBUG(dbgs() << "): BB#" << BBI.BB->getNumber() << " (T:" in runOnMachineFunction()
369 DEBUG(dbgs() << "Ifcvt (Diamond): BB#" << BBI.BB->getNumber() << " (T:" in runOnMachineFunction()
[all …]
DMachineSSAUpdater.cpp62 bool MachineSSAUpdater::HasValueForBlock(MachineBasicBlock *BB) const { in HasValueForBlock()
63 return getAvailableVals(AV).count(BB); in HasValueForBlock()
68 void MachineSSAUpdater::AddAvailableValue(MachineBasicBlock *BB, unsigned V) { in AddAvailableValue() argument
69 getAvailableVals(AV)[BB] = V; in AddAvailableValue()
74 unsigned MachineSSAUpdater::GetValueAtEndOfBlock(MachineBasicBlock *BB) { in GetValueAtEndOfBlock() argument
75 return GetValueAtEndOfBlockInternal(BB); in GetValueAtEndOfBlock()
79 unsigned LookForIdenticalPHI(MachineBasicBlock *BB, in LookForIdenticalPHI() argument
81 if (BB->empty()) in LookForIdenticalPHI()
84 MachineBasicBlock::iterator I = BB->front(); in LookForIdenticalPHI()
91 while (I != BB->end() && I->isPHI()) { in LookForIdenticalPHI()
[all …]
/external/llvm/lib/Transforms/Scalar/
DJumpThreading.cpp197 BasicBlock *BB = &*I; in runImpl() local
199 while (ProcessBlock(BB)) in runImpl()
206 if (pred_empty(BB) && in runImpl()
207 BB != &BB->getParent()->getEntryBlock()) { in runImpl()
208 DEBUG(dbgs() << " JT: Deleting dead block '" << BB->getName() in runImpl()
209 << "' with terminator: " << *BB->getTerminator() << '\n'); in runImpl()
210 LoopHeaders.erase(BB); in runImpl()
211 LVI->eraseBlock(BB); in runImpl()
212 DeleteDeadBlock(BB); in runImpl()
217 BranchInst *BI = dyn_cast<BranchInst>(BB->getTerminator()); in runImpl()
[all …]
/external/llvm/include/llvm/IR/
DCFG.h91 inline pred_iterator pred_begin(BasicBlock *BB) { return pred_iterator(BB); } in pred_begin() argument
92 inline const_pred_iterator pred_begin(const BasicBlock *BB) { in pred_begin() argument
93 return const_pred_iterator(BB); in pred_begin()
95 inline pred_iterator pred_end(BasicBlock *BB) { return pred_iterator(BB, true);} in pred_end() argument
96 inline const_pred_iterator pred_end(const BasicBlock *BB) { in pred_end() argument
97 return const_pred_iterator(BB, true); in pred_end()
99 inline bool pred_empty(const BasicBlock *BB) { in pred_empty() argument
100 return pred_begin(BB) == pred_end(BB); in pred_empty()
102 inline pred_range predecessors(BasicBlock *BB) { in predecessors() argument
103 return pred_range(pred_begin(BB), pred_end(BB)); in predecessors()
[all …]
/external/swiftshader/third_party/llvm-7.0/llvm/lib/CodeGen/
DMachineSSAUpdater.cpp67 bool MachineSSAUpdater::HasValueForBlock(MachineBasicBlock *BB) const { in HasValueForBlock()
68 return getAvailableVals(AV).count(BB); in HasValueForBlock()
73 void MachineSSAUpdater::AddAvailableValue(MachineBasicBlock *BB, unsigned V) { in AddAvailableValue() argument
74 getAvailableVals(AV)[BB] = V; in AddAvailableValue()
79 unsigned MachineSSAUpdater::GetValueAtEndOfBlock(MachineBasicBlock *BB) { in GetValueAtEndOfBlock() argument
80 return GetValueAtEndOfBlockInternal(BB); in GetValueAtEndOfBlock()
84 unsigned LookForIdenticalPHI(MachineBasicBlock *BB, in LookForIdenticalPHI() argument
86 if (BB->empty()) in LookForIdenticalPHI()
89 MachineBasicBlock::iterator I = BB->begin(); in LookForIdenticalPHI()
96 while (I != BB->end() && I->isPHI()) { in LookForIdenticalPHI()
[all …]
/external/llvm/lib/Analysis/
DCFG.cpp29 const BasicBlock *BB = &F.getEntryBlock(); in FindFunctionBackedges() local
30 if (succ_empty(BB)) in FindFunctionBackedges()
37 Visited.insert(BB); in FindFunctionBackedges()
38 VisitStack.push_back(std::make_pair(BB, succ_begin(BB))); in FindFunctionBackedges()
39 InStack.insert(BB); in FindFunctionBackedges()
47 BB = *I++; in FindFunctionBackedges()
48 if (Visited.insert(BB).second) { in FindFunctionBackedges()
53 if (InStack.count(BB)) in FindFunctionBackedges()
54 Result.push_back(std::make_pair(ParentBB, BB)); in FindFunctionBackedges()
59 InStack.insert(BB); in FindFunctionBackedges()
[all …]
DBranchProbabilityInfo.cpp115 bool BranchProbabilityInfo::calcUnreachableHeuristics(const BasicBlock *BB) { in calcUnreachableHeuristics() argument
116 const TerminatorInst *TI = BB->getTerminator(); in calcUnreachableHeuristics()
123 BB->getTerminatingDeoptimizeCall()) in calcUnreachableHeuristics()
124 PostDominatedByUnreachable.insert(BB); in calcUnreachableHeuristics()
131 for (succ_const_iterator I = succ_begin(BB), E = succ_end(BB); I != E; ++I) { in calcUnreachableHeuristics()
141 PostDominatedByUnreachable.insert(BB); in calcUnreachableHeuristics()
152 PostDominatedByUnreachable.insert(BB); in calcUnreachableHeuristics()
161 setEdgeProbability(BB, SuccIdx, Prob); in calcUnreachableHeuristics()
173 setEdgeProbability(BB, SuccIdx, UnreachableProb); in calcUnreachableHeuristics()
175 setEdgeProbability(BB, SuccIdx, ReachableProb); in calcUnreachableHeuristics()
[all …]
/external/swiftshader/third_party/llvm-7.0/llvm/lib/Analysis/
DCFG.cpp29 const BasicBlock *BB = &F.getEntryBlock(); in FindFunctionBackedges() local
30 if (succ_empty(BB)) in FindFunctionBackedges()
37 Visited.insert(BB); in FindFunctionBackedges()
38 VisitStack.push_back(std::make_pair(BB, succ_begin(BB))); in FindFunctionBackedges()
39 InStack.insert(BB); in FindFunctionBackedges()
47 BB = *I++; in FindFunctionBackedges()
48 if (Visited.insert(BB).second) { in FindFunctionBackedges()
53 if (InStack.count(BB)) in FindFunctionBackedges()
54 Result.push_back(std::make_pair(ParentBB, BB)); in FindFunctionBackedges()
59 InStack.insert(BB); in FindFunctionBackedges()
[all …]
DBranchProbabilityInfo.cpp137 BranchProbabilityInfo::updatePostDominatedByUnreachable(const BasicBlock *BB) { in updatePostDominatedByUnreachable() argument
138 const TerminatorInst *TI = BB->getTerminator(); in updatePostDominatedByUnreachable()
145 BB->getTerminatingDeoptimizeCall()) in updatePostDominatedByUnreachable()
146 PostDominatedByUnreachable.insert(BB); in updatePostDominatedByUnreachable()
154 PostDominatedByUnreachable.insert(BB); in updatePostDominatedByUnreachable()
158 for (auto *I : successors(BB)) in updatePostDominatedByUnreachable()
163 PostDominatedByUnreachable.insert(BB); in updatePostDominatedByUnreachable()
168 BranchProbabilityInfo::updatePostDominatedByColdCall(const BasicBlock *BB) { in updatePostDominatedByColdCall() argument
169 assert(!PostDominatedByColdCall.count(BB)); in updatePostDominatedByColdCall()
170 const TerminatorInst *TI = BB->getTerminator(); in updatePostDominatedByColdCall()
[all …]
/external/swiftshader/third_party/LLVM/lib/Transforms/Utils/
DBasicBlockUtils.cpp35 void llvm::DeleteDeadBlock(BasicBlock *BB) { in DeleteDeadBlock() argument
36 assert((pred_begin(BB) == pred_end(BB) || in DeleteDeadBlock()
38 BB->getSinglePredecessor() == BB) && "Block is not dead!"); in DeleteDeadBlock()
39 TerminatorInst *BBTerm = BB->getTerminator(); in DeleteDeadBlock()
44 BBTerm->getSuccessor(i)->removePredecessor(BB); in DeleteDeadBlock()
47 while (!BB->empty()) { in DeleteDeadBlock()
48 Instruction &I = BB->back(); in DeleteDeadBlock()
56 BB->getInstList().pop_back(); in DeleteDeadBlock()
60 BB->eraseFromParent(); in DeleteDeadBlock()
67 void llvm::FoldSingleEntryPHINodes(BasicBlock *BB, Pass *P) { in FoldSingleEntryPHINodes() argument
[all …]

12345678910>>...111