/external/llvm/include/llvm/Analysis/ |
BranchProbabilityInfo.h | 97 /// This returns the sum of all raw edge weights from Src to Dst. 106 /// weights are calculated carefully before using! 118 // weight to an edge that may have siblings with non-zero weights. This can 123 DenseMap<Edge, uint32_t> Weights; 137 /// \brief Get sum of the block successors' weights.
|
/external/llvm/include/llvm/IR/ |
MDBuilder.h | 57 /// \brief Return metadata containing two branch weights. 59 uint32_t Weights[] = { TrueWeight, FalseWeight }; 60 return createBranchWeights(Weights); 63 /// \brief Return metadata containing a number of branch weights. 64 MDNode *createBranchWeights(ArrayRef<uint32_t> Weights) { 65 assert(Weights.size() >= 2 && "Need at least two branch weights!"); 67 SmallVector<Value *, 4> Vals(Weights.size()+1); 71 for (unsigned i = 0, e = Weights.size(); i != e; ++i) 72 Vals[i+1] = ConstantInt::get(Int32Ty, Weights[i]) [all...] |
/external/llvm/lib/Analysis/ |
ProfileDataLoaderPass.cpp | 131 /// edge into branch weights for each conditional branch (a branch with 2 or 147 // Load the weights of all edges leading from this terminator. 150 SmallVector<uint32_t, 4> Weights(NumSuccessors); 153 Weights[s] = (uint32_t)PB.getEdgeWeight(edge); 155 << Weights[s] << "\n"); 164 MDNode *Node = MDB.createBranchWeights(Weights);
|
BranchProbabilityInfo.cpp | 35 // Weights are for internal use only. They are used by heuristics to help to 38 // Using "Loop Branch Heuristics" we predict weights of edges for the 120 /// \brief Calculate edge weights for successors lead to unreachable. 185 // Ensure there are weights for all of the successors. Note that the first 190 // Build up the final weights that will be used in a temporary buffer, but 194 SmallVector<uint32_t, 2> Weights; 195 Weights.reserve(TI->getNumSuccessors()); 200 Weights.push_back( 203 assert(Weights.size() == TI->getNumSuccessors() && "Checked above"); 205 setEdgeWeight(BB, i, Weights[i]) [all...] |
/external/llvm/unittests/IR/ |
IRBuilderTest.cpp | 92 MDNode *Weights = MDBuilder(getGlobalContext()).createBranchWeights(42, 13); 93 BI = Builder.CreateCondBr(Builder.getTrue(), TBB, FBB, Weights); 99 EXPECT_EQ(Weights, TI->getMetadata(LLVMContext::MD_prof));
|
/external/llvm/lib/Transforms/Utils/ |
Local.cpp | 130 // Collect branch weights into a vector. 131 SmallVector<uint32_t, 8> Weights; 136 Weights.push_back(CI->getValue().getZExtValue()); 140 Weights[0] += Weights[idx+1]; 142 std::swap(Weights[idx+1], Weights.back()); 143 Weights.pop_back(); 146 createBranchWeights(Weights)); [all...] |
SimplifyCFG.cpp | 617 // Collect branch weights into a vector. 618 SmallVector<uint32_t, 8> Weights; 626 Weights.push_back(CI->getValue().getZExtValue()); 632 std::swap(Weights[i.getCaseIndex()+1], Weights.back()); 633 Weights.pop_back(); 639 if (HasWeight && Weights.size() >= 2) 642 createBranchWeights(Weights)); 721 /// Get Weights of a given TerminatorInst, the default weight is at the front 725 SmallVectorImpl<uint64_t> &Weights) { [all...] |
/external/openfst/src/include/fst/ |
accumulator.h | 19 // Classes to accumulate arc weights. Useful for weight lookahead. 40 // This class accumulates arc weights using the semiring Plus(). 77 // This class accumulates arc weights using the log semiring Plus() 79 // and from log64 weights. 135 vector<double> *Weights() { return &weights_; } 148 // weights_. Position -1 means no pre-computed weights for that 157 // This class accumulates arc weights using the log semiring Plus() 159 // from log64 weights. The member function Init(fst) has to be called 188 vector<double> &weights = *data_->Weights(); local 386 vector<double>* weights; \/\/ Accumulated weights for this state. member in struct:fst::CacheLogAccumulatorData::CacheState [all...] |
/external/llvm/include/llvm/CodeGen/ |
MachineBasicBlock.h | 74 /// Weights - Keep track of the weights to the successors. This vector 77 std::vector<uint32_t> Weights; 359 /// parameter is stored in Weights list and it may be used by
|