Home
last modified time | relevance | path

Searched refs:WeightSum (Results 1 – 1 of 1) sorted by relevance

/llvm-project-15.0.7/llvm/lib/Analysis/
H A DBranchProbabilityInfo.cpp400 uint64_t WeightSum = 0; in calcMetadataWeights() local
413 WeightSum += Weights.back(); in calcMetadataWeights()
428 (WeightSum > UINT32_MAX) ? WeightSum / UINT32_MAX + 1 : 1; in calcMetadataWeights()
431 WeightSum = 0; in calcMetadataWeights()
434 WeightSum += Weights[I]; in calcMetadataWeights()
437 assert(WeightSum <= UINT32_MAX && in calcMetadataWeights()
440 if (WeightSum == 0 || ReachableIdxs.size() == 0) { in calcMetadataWeights()
443 WeightSum = TI->getNumSuccessors(); in calcMetadataWeights()
449 BP.push_back({ Weights[I], static_cast<uint32_t>(WeightSum) }); in calcMetadataWeights()