| /freebsd/contrib/llvm-project/llvm/include/llvm/FuzzMutate/ |
| H A D | Operations.h | 44 LLVM_ABI OpDescriptor selectDescriptor(unsigned Weight); 45 LLVM_ABI OpDescriptor fnegDescriptor(unsigned Weight); 46 LLVM_ABI OpDescriptor binOpDescriptor(unsigned Weight, 48 LLVM_ABI OpDescriptor cmpOpDescriptor(unsigned Weight, 51 LLVM_ABI OpDescriptor splitBlockDescriptor(unsigned Weight); 52 LLVM_ABI OpDescriptor gepDescriptor(unsigned Weight); 53 LLVM_ABI OpDescriptor extractValueDescriptor(unsigned Weight); 54 LLVM_ABI OpDescriptor insertValueDescriptor(unsigned Weight); 55 LLVM_ABI OpDescriptor extractElementDescriptor(unsigned Weight); 56 LLVM_ABI OpDescriptor insertElementDescriptor(unsigned Weight); [all …]
|
| H A D | Random.h | 60 ReservoirSampler &sample(const T &Item, uint64_t Weight) { in sample() argument 61 if (!Weight) in sample() 64 TotalWeight += Weight; in sample() 66 if (uniform<uint64_t>(RandGen, 1, TotalWeight) <= Weight) in sample() 83 uint64_t Weight) { in makeSampler() argument 85 RS.sample(Item, Weight); in makeSampler()
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/Transforms/Instrumentation/ |
| H A D | CFGMST.h | 148 uint64_t Weight = 2; in buildEdges() local 161 Weight = BPI->getEdgeProbability(&BB, TargetBB).scale(scaleFactor); in buildEdges() 170 Weight = 0; in buildEdges() 172 if (Weight == 0) in buildEdges() 173 Weight++; in buildEdges() 174 auto *E = &addEdge(&BB, TargetBB, Weight); in buildEdges() 178 << TargetBB->getName() << " w=" << Weight << "\n"); in buildEdges() 182 if (Weight > MaxEntryOutWeight) { in buildEdges() 183 MaxEntryOutWeight = Weight; in buildEdges() 190 if (Weight > MaxExitInWeight) { in buildEdges() [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/Analysis/ |
| H A D | BlockFrequencyInfoImpl.cpp | 95 using Weight = BlockFrequencyInfoImplBase::Weight; typedef 122 BlockMass takeMass(uint32_t Weight); 134 BlockMass DitheringDistributer::takeMass(uint32_t Weight) { in takeMass() argument 135 assert(Weight && "invalid weight"); in takeMass() 136 assert(Weight <= RemWeight); in takeMass() 137 BlockMass Mass = RemMass * BranchProbability(Weight, RemWeight); in takeMass() 140 RemWeight -= Weight; in takeMass() 146 Weight::DistType Type) { in add() 159 Weights.push_back(Weight(Type, Node, Amount)); in add() 162 static void combineWeight(Weight &W, const Weight &OtherW) { in combineWeight() [all …]
|
| H A D | BranchProbabilityInfo.cpp | 672 auto Weight = getEstimatedEdgeWeight({SrcLoopBB, DstLoopBB}); in getMaxEstimatedEdgeWeight() local 674 if (!Weight) in getMaxEstimatedEdgeWeight() 677 if (!MaxWeight || *MaxWeight < *Weight) in getMaxEstimatedEdgeWeight() 678 MaxWeight = Weight; in getMaxEstimatedEdgeWeight() 889 std::optional<uint32_t> Weight; in calcEstimatedHeuristics() local 893 Weight = getEstimatedEdgeWeight(Edge); in calcEstimatedHeuristics() 897 Weight != static_cast<uint32_t>(BlockExecWeight::ZERO)) { in calcEstimatedHeuristics() 899 Weight = std::max( in calcEstimatedHeuristics() 901 Weight.value_or(static_cast<uint32_t>(BlockExecWeight::DEFAULT)) / in calcEstimatedHeuristics() 907 Weight != static_cast<uint32_t>(BlockExecWeight::ZERO)) { in calcEstimatedHeuristics() [all …]
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/Transforms/IPO/ |
| H A D | ProfiledCallGraph.h | 26 ProfiledCallGraphNode *Target, uint64_t Weight) in ProfiledCallGraphEdge() 27 : Source(Source), Target(Target), Weight(Weight) {} in ProfiledCallGraphEdge() 30 uint64_t Weight; member 108 uint64_t Weight; variable 111 Weight = 0; 121 Weight = std::max(CallsiteCount, CalleeEntryCount); 124 addProfiledCall(Caller->getFuncName(), Callee->getFuncName(), Weight); 152 uint64_t Weight = 0) { 158 ProfiledCallGraphEdge Edge(CallerIt->second, CalleeIt->second, Weight); 163 Edge.Weight += EdgeIt->Weight; [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/FuzzMutate/ |
| H A D | Operations.cpp | 100 OpDescriptor llvm::fuzzerop::selectDescriptor(unsigned Weight) { in selectDescriptor() argument 104 return {Weight, in selectDescriptor() 109 OpDescriptor llvm::fuzzerop::fnegDescriptor(unsigned Weight) { in fnegDescriptor() argument 113 return {Weight, {anyFloatOrVecFloatType()}, buildOp}; in fnegDescriptor() 116 OpDescriptor llvm::fuzzerop::binOpDescriptor(unsigned Weight, in binOpDescriptor() argument 135 return {Weight, {anyIntOrVecIntType(), matchFirstType()}, buildOp}; in binOpDescriptor() 141 return {Weight, {anyFloatOrVecFloatType(), matchFirstType()}, buildOp}; in binOpDescriptor() 148 OpDescriptor llvm::fuzzerop::cmpOpDescriptor(unsigned Weight, in cmpOpDescriptor() argument 158 return {Weight, {anyIntOrVecIntType(), matchFirstType()}, buildOp}; in cmpOpDescriptor() 160 return {Weight, {anyFloatOrVecFloatType(), matchFirstType()}, buildOp}; in cmpOpDescriptor() [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/CodeGen/ |
| H A D | CalcSpillWeights.cpp | 142 float Weight = weightCalcHelper(LI); in calculateSpillWeightAndHint() local 144 if (Weight < 0) in calculateSpillWeightAndHint() 146 LI.setWeight(Weight); in calculateSpillWeightAndHint() 212 float Weight; in weightCalcHelper() member 215 : Reg(R), Weight(W), IsCSR(IsCSR) {} in weightCalcHelper() 220 if (Weight != Rhs.Weight) in weightCalcHelper() 221 return (Weight > Rhs.Weight); in weightCalcHelper() 267 stack_float_t Weight = 1.0f; in weightCalcHelper() local 279 Weight = LiveIntervals::getSpillWeight(Writes, Reads, &MBFI, *MI, PSI); in weightCalcHelper() 283 Weight *= 3; in weightCalcHelper() [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/Target/Hexagon/ |
| H A D | HexagonISelDAGToDAG.cpp | 1813 int Weight; member 1818 WeightedLeaf(SDValue Value, int Weight, int InsertionOrder) : in WeightedLeaf() 1819 Value(Value), Weight(Weight), InsertionOrder(InsertionOrder) { in WeightedLeaf() 1820 assert(Weight >= 0 && "Weight must be >= 0"); in WeightedLeaf() 1825 return A.Weight == B.Weight ? in Compare() 1827 (A.Weight > B.Weight); in Compare() 1888 L.Weight = 1000; in pushToBottom() 1914 if (!Result.Value.getNode() || Result.Weight > L.Weight || in findSHL() 1915 (Result.Weight == L.Weight && Result.InsertionOrder > L.InsertionOrder)) in findSHL() 1941 if (!Result.Value.getNode() || Result.Weight > L.Weight || in findMULbyConst() [all …]
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/Transforms/Utils/ |
| H A D | SampleProfileInference.h | 28 uint64_t Weight{0}; 46 uint64_t Weight{0}; 253 Block.Weight = It->second; in createFlowFunction() 256 Block.Weight = 0; in createFlowFunction() 293 if (EntryBlock.Weight == 0 && !EntryBlock.HasUnknownWeight) { in createFlowFunction() 294 EntryBlock.Weight = 1; in createFlowFunction()
|
| H A D | SampleProfileLoaderBaseImpl.h | 539 ErrorOr<uint64_t> Weight = getBlockWeight(&BB); 540 if (Weight) { 541 BlockWeights[&BB] = Weight.get(); 602 uint64_t Weight = BlockWeights[EC]; 621 Weight = std::max(Weight, BlockWeights[BB2]); 628 BlockWeights[EC] = Weight; 929 ErrorOr<uint64_t> Weight = getBlockWeight(&BI); 930 if (Weight) 931 SampleBlockWeights[&BI] = Weight.get();
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/ProfileData/ |
| H A D | SampleProf.h | 352 sampleprof_error addSamples(uint64_t S, uint64_t Weight = 1) { 354 NumSamples = SaturatingMultiplyAdd(S, Weight, NumSamples, &Overflowed); 374 uint64_t Weight = 1) { 378 SaturatingMultiplyAdd(S, Weight, TargetSamples, &Overflowed); 434 uint64_t Weight = 1); 764 sampleprof_error addTotalSamples(uint64_t Num, uint64_t Weight = 1) { 767 SaturatingMultiplyAdd(Num, Weight, TotalSamples, &Overflowed); 783 sampleprof_error addHeadSamples(uint64_t Num, uint64_t Weight = 1) { 786 SaturatingMultiplyAdd(Num, Weight, TotalHeadSamples, &Overflowed); 792 uint64_t Num, uint64_t Weight = 1) { [all …]
|
| H A D | InstrProf.h | 432 uint64_t Weight; member 434 uint64_t Weight = 1) 435 : FunctionNameRefs(Trace), Weight(Weight) {} in FunctionNameRefs() 873 LLVM_ABI void merge(InstrProfValueSiteRecord &Input, uint64_t Weight, 939 LLVM_ABI void merge(InstrProfRecord &Other, uint64_t Weight, 1039 uint64_t Weight,
|
| H A D | InstrProfWriter.h | 115 LLVM_ABI void addRecord(NamedInstrProfRecord &&I, uint64_t Weight, 227 uint64_t Weight, function_ref<void(Error)> Warn);
|
| /freebsd/contrib/llvm-project/llvm/utils/TableGen/Common/ |
| H A D | CodeGenRegisters.h | 567 unsigned Weight = 0; member 595 unsigned Weight = 0; // Cache the sum of all unit weights. member 784 unsigned newRegUnit(unsigned Weight) { in newRegUnit() argument 786 RU.Weight = Weight; in newRegUnit() 841 unsigned Weight = 0; in getRegUnitSetWeight() local 843 Weight += getRegUnit(Unit).Weight; in getRegUnitSetWeight() 844 return Weight; in getRegUnitSetWeight() 857 getRegUnit(RUID).Weight += Inc; in increaseRegUnitWeight()
|
| H A D | CodeGenRegisters.cpp | 526 unsigned Weight = 0; in getWeight() local 528 Weight += RegBank.getRegUnit(RegUnit).Weight; in getWeight() 529 return Weight; in getWeight() 1720 unsigned Weight = 0; member 1798 unsigned Weight = 0; in computeUberWeights() local 1801 unsigned UWeight = RegBank.getRegUnit(U).Weight; in computeUberWeights() 1806 Weight += UWeight; in computeUberWeights() 1809 MaxWeight = std::max(MaxWeight, Weight); in computeUberWeights() 1811 if (S.Weight != MaxWeight) { in computeUberWeights() 1820 S.Weight = MaxWeight; in computeUberWeights() [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/Transforms/Utils/ |
| H A D | SampleProfileInference.cpp | 1095 if (Block.Weight > 0) { in initializeNetwork() 1096 Network.addEdge(Bout, Bin, Block.Weight, AuxCostDec); in initializeNetwork() 1097 Network.addEdge(S1, Bout, Block.Weight, 0); in initializeNetwork() 1098 Network.addEdge(Bin, T1, Block.Weight, 0); in initializeNetwork() 1115 if (Jump.Weight > 0) { in initializeNetwork() 1116 Network.addEdge(Jout, Jin, Jump.Weight, AuxCostDec); in initializeNetwork() 1117 Network.addEdge(S1, Jout, Jump.Weight, 0); in initializeNetwork() 1118 Network.addEdge(Jin, T1, Jump.Weight, 0); in initializeNetwork() 1143 if (Block.Weight == 0) in assignBlockCosts() 1178 assert(Jump.Weight > 0 && "found zero-weight jump with a positive weight"); in assignJumpCosts() [all …]
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/CodeGen/ |
| H A D | LiveInterval.h | 718 float Weight = 0.0; // weight of this interval variable 722 float weight() const { return Weight; } in weight() 723 void incrementWeight(float Inc) { Weight += Inc; } in incrementWeight() 724 void setWeight(float Value) { Weight = Value; } in setWeight() 726 LiveInterval(Register Reg, float Weight) : Reg(Reg), Weight(Weight) {} in LiveInterval() argument 829 bool isSpillable() const { return Weight != huge_valf; } in isSpillable() 832 void markNotSpillable() { Weight = huge_valf; } in markNotSpillable()
|
| /freebsd/contrib/llvm-project/compiler-rt/lib/fuzzer/ |
| H A D | FuzzerDataFlowTrace.cpp | 95 auto &Weight = Res[FunctionID]; in FunctionWeights() local 97 Weight = FunctionsWithDFT.count(FunctionID) ? 1000. : 1; in FunctionWeights() 99 Weight /= SmallestNonZeroCounter(Counters); in FunctionWeights() 101 Weight *= NumberOfUncoveredBlocks(Counters) + 1; in FunctionWeights()
|
| /freebsd/contrib/llvm-project/llvm/lib/IR/ |
| H A D | ProfDataUtils.cpp | 78 ConstantInt *Weight = in extractFromBranchWeightMD() local 80 assert(Weight && "Malformed branch_weight in MD_prof node"); in extractFromBranchWeightMD() 81 assert(Weight->getValue().getActiveBits() <= (sizeof(T) * 8) && in extractFromBranchWeightMD() 83 Weights[Idx - WeightsIdx] = Weight->getZExtValue(); in extractFromBranchWeightMD()
|
| /freebsd/contrib/llvm-project/llvm/lib/ProfileData/ |
| H A D | InstrProfWriter.cpp | 156 void InstrProfWriter::addRecord(NamedInstrProfRecord &&I, uint64_t Weight, in addRecord() argument 160 addRecord(Name, Hash, std::move(I), Weight, Warn); in addRecord() 195 InstrProfRecord &&I, uint64_t Weight, in addRecord() argument 209 if (Weight > 1) in addRecord() 210 Dest.scale(Weight, 1, MapWarn); in addRecord() 213 Dest.merge(I, Weight, MapWarn); in addRecord() 642 OS.write(Trace.Weight); in writeImpl() 852 OS << "# Weight:\n" << Trace.Weight << "\n"; in writeTextTemporalProfTraceData()
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/ADT/ |
| H A D | APFixedPoint.h | 48 FixedPointSemantics(unsigned Width, Lsb Weight, bool IsSigned, in FixedPointSemantics() argument 50 : Width(Width), LsbWeight(Weight.LsbWeight), IsSigned(IsSigned), in FixedPointSemantics() 52 assert(isUInt<WidthBitWidth>(Width) && isInt<LsbWeightBitWidth>(Weight.LsbWeight)); in FixedPointSemantics()
|
| /freebsd/contrib/llvm-project/llvm/lib/Target/WebAssembly/ |
| H A D | WebAssemblyRegColoring.cpp | 68 float Weight = 0.0f; in computeWeight() local 70 Weight += LiveIntervals::getSpillWeight(MO.isDef(), MO.isUse(), MBFI, in computeWeight() 72 return Weight; in computeWeight()
|
| /freebsd/contrib/llvm-project/llvm/include/llvm/Analysis/ |
| H A D | CFGPrinter.h | 305 ConstantInt *Weight = 307 if (!Weight) 309 return (TTAttr + "label=\"W:" + std::to_string(Weight->getZExtValue()) +
|
| /freebsd/contrib/llvm-project/llvm/lib/Transforms/Scalar/ |
| H A D | Reassociate.cpp | 432 auto [I, Weight] = Worklist.pop_back_val(); in LinearizeExprTree() 438 LLVM_DEBUG(dbgs() << "OPERAND: " << *Op << " (" << Weight << ")\n"); in LinearizeExprTree() 446 LLVM_DEBUG(dbgs() << "DIRECT ADD: " << *Op << " (" << Weight << ")\n"); in LinearizeExprTree() 447 Worklist.push_back(std::make_pair(BO, Weight)); in LinearizeExprTree() 460 << "ADD USES LEAF: " << *Op << " (" << Weight << ")\n"); in LinearizeExprTree() 462 Leaves[Op] = Weight; in LinearizeExprTree() 472 It->second += Weight; in LinearizeExprTree() 473 assert(It->second >= Weight && "Weight overflows"); in LinearizeExprTree() 481 Weight = It->second; in LinearizeExprTree() 506 << "MORPH LEAF: " << *Op << " (" << Weight << ") TO "); in LinearizeExprTree() [all …]
|