Home
last modified time | relevance | path

Searched refs:PSI (Results 1 – 25 of 118) sorted by relevance

12345

/freebsd/contrib/llvm-project/llvm/include/llvm/Transforms/Utils/
H A DSizeOpts.h41 static inline bool isPGSOColdCodeOnly(ProfileSummaryInfo *PSI) { in isPGSOColdCodeOnly() argument
43 (PSI->hasInstrumentationProfile() && PGSOColdCodeOnlyForInstrPGO) || in isPGSOColdCodeOnly()
44 (PSI->hasSampleProfile() && in isPGSOColdCodeOnly()
45 ((!PSI->hasPartialSampleProfile() && PGSOColdCodeOnlyForSamplePGO) || in isPGSOColdCodeOnly()
46 (PSI->hasPartialSampleProfile() && in isPGSOColdCodeOnly()
48 (PGSOLargeWorkingSetSizeOnly && !PSI->hasLargeWorkingSetSize()); in isPGSOColdCodeOnly()
52 bool shouldFuncOptimizeForSizeImpl(const FuncT *F, ProfileSummaryInfo *PSI, in shouldFuncOptimizeForSizeImpl() argument
55 if (!PSI || !BFI || !PSI->hasProfileSummary()) in shouldFuncOptimizeForSizeImpl()
61 if (isPGSOColdCodeOnly(PSI)) in shouldFuncOptimizeForSizeImpl()
62 return PSI->isFunctionColdInCallGraph(F, *BFI); in shouldFuncOptimizeForSizeImpl()
[all …]
H A DSampleProfileLoaderBaseUtil.h41 ProfileSummaryInfo *PSI) const;
43 ProfileSummaryInfo *PSI) const;
46 ProfileSummaryInfo *PSI) const;
89 bool callsiteIsHot(const FunctionSamples *CallsiteFS, ProfileSummaryInfo *PSI,
H A DCloning.h255 ProfileSummaryInfo *PSI = nullptr,
258 : GetAssumptionCache(GetAssumptionCache), PSI(PSI), CallerBFI(CallerBFI), in GetAssumptionCache()
264 ProfileSummaryInfo *PSI; variable
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Utils/
H A DSizeOpts.cpp64 ProfileSummaryInfo *PSI, in isFunctionColdInCallGraph()
66 return PSI->isFunctionColdInCallGraph(F, BFI); in isFunctionColdInCallGraph()
70 ProfileSummaryInfo *PSI, in isFunctionHotInCallGraphNthPercentile()
72 return PSI->isFunctionHotInCallGraphNthPercentile(CutOff, F, BFI); in isFunctionHotInCallGraphNthPercentile()
76 ProfileSummaryInfo *PSI, in isFunctionColdInCallGraphNthPercentile()
78 return PSI->isFunctionColdInCallGraphNthPercentile(CutOff, F, BFI); in isFunctionColdInCallGraphNthPercentile()
81 ProfileSummaryInfo *PSI, in isColdBlock()
83 return PSI->isColdBlock(BB, BFI); in isColdBlock()
87 ProfileSummaryInfo *PSI, in isHotBlockNthPercentile()
89 return PSI->isHotBlockNthPercentile(CutOff, BB, BFI); in isHotBlockNthPercentile()
[all …]
H A DSampleProfileLoaderBaseUtil.cpp64 bool callsiteIsHot(const FunctionSamples *CallsiteFS, ProfileSummaryInfo *PSI, in callsiteIsHot() argument
69 assert(PSI && "PSI is expected to be non null"); in callsiteIsHot()
72 return !PSI->isColdCount(CallsiteTotalSamples); in callsiteIsHot()
74 return PSI->isHotCount(CallsiteTotalSamples); in callsiteIsHot()
98 ProfileSummaryInfo *PSI) const { in countUsedRecords()
111 if (callsiteIsHot(CalleeSamples, PSI, ProfAccForSymsInList)) in countUsedRecords()
112 Count += countUsedRecords(CalleeSamples, PSI); in countUsedRecords()
123 ProfileSummaryInfo *PSI) const { in countBodyRecords()
130 if (callsiteIsHot(CalleeSamples, PSI, ProfAccForSymsInList)) in countBodyRecords()
131 Count += countBodyRecords(CalleeSamples, PSI); in countBodyRecords()
[all …]
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/
H A DMachineFunctionSplitter.cpp110 ProfileSummaryInfo *PSI) { in isColdBlock() argument
114 if (PSI->hasInstrumentationProfile() || PSI->hasCSInstrumentationProfile()) { in isColdBlock()
120 return PSI->isColdCountNthPercentile(PercentileCutoff, *Count); in isColdBlock()
122 } else if (PSI->hasSampleProfile()) { in isColdBlock()
162 ProfileSummaryInfo *PSI = nullptr; in runOnMachineFunction() local
165 PSI = &getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnMachineFunction()
170 if (PSI->hasSampleProfile() && !PSI->isFunctionHotInCallGraph(&MF, *MBFI)) { in runOnMachineFunction()
186 else if (UseProfileData && isColdBlock(MBB, MBFI, PSI) && in runOnMachineFunction()
199 if (!isColdBlock(*LP, MBFI, PSI) || !TII.isMBBSafeToSplitToCold(*LP)) in runOnMachineFunction()
H A DTailDuplication.cpp91 auto *PSI = &getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnMachineFunction() local
92 auto *MBFI = (PSI && PSI->hasProfileSummary()) ? in runOnMachineFunction()
97 Duplicator.initMF(MF, PreRegAlloc, MBPI, MBFI ? MBFIW.get() : nullptr, PSI, in runOnMachineFunction()
113 auto *PSI = MFAM.getResult<ModuleAnalysisManagerMachineFunctionProxy>(MF) in run() local
116 auto *MBFI = (PSI && PSI->hasProfileSummary() in run()
123 Duplicator.initMF(MF, PreRegAlloc, MBPI, MBFI ? MBFIW.get() : nullptr, PSI, in run()
H A DMachineSizeOpts.cpp28 ProfileSummaryInfo *PSI, in shouldOptimizeForSize() argument
33 return shouldFuncOptimizeForSizeImpl(MF, PSI, MBFI, QueryType); in shouldOptimizeForSize()
37 ProfileSummaryInfo *PSI, in shouldOptimizeForSize() argument
43 return shouldOptimizeForSizeImpl(MBB, PSI, MBFI, QueryType); in shouldOptimizeForSize()
47 ProfileSummaryInfo *PSI, in shouldOptimizeForSize() argument
56 return shouldOptimizeForSizeImpl(BlockFreq, PSI, &MBFIW->getMBFI(), in shouldOptimizeForSize()
H A DStaticDataAnnotator.cpp50 const ProfileSummaryInfo *PSI = nullptr; member in StaticDataAnnotator
71 PSI = &getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnModule()
73 if (!PSI->hasProfileSummary()) in runOnModule()
90 StringRef SectionPrefix = SDPI->getConstantSectionPrefix(&GV, PSI); in runOnModule()
H A DStaticDataSplitter.cpp48 const ProfileSummaryInfo *PSI = nullptr; member in StaticDataSplitter
103 PSI = &getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnMachineFunction()
108 const bool ProfileAvailable = PSI && PSI->hasProfileSummary() && MBFI && in runOnMachineFunction()
192 if (Count && PSI->isColdCount(*Count)) in partitionStaticDataWithProfiles()
H A DExpandMemCmp.cpp832 ProfileSummaryInfo *PSI, BlockFrequencyInfo *BFI, in expandMemCmp() argument
855 bool OptForSize = llvm::shouldOptimizeForSize(CI->getParent(), PSI, BFI); in expandMemCmp()
892 const DataLayout &DL, ProfileSummaryInfo *PSI,
898 ProfileSummaryInfo *PSI,
923 auto *PSI = &getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnFunction() local
924 auto *BFI = (PSI && PSI->hasProfileSummary()) ? in runOnFunction()
930 auto PA = runImpl(F, TLI, TTI, TL, PSI, BFI, DT); in runOnFunction()
947 const DataLayout &DL, ProfileSummaryInfo *PSI, in runOnBlock() argument
957 expandMemCmp(CI, TTI, TL, &DL, PSI, BFI, DTU, Func == LibFunc_bcmp)) { in runOnBlock()
966 const TargetLowering *TL, ProfileSummaryInfo *PSI, in runImpl() argument
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Instrumentation/
H A DPGOForceFunctionAttrs.cpp18 static bool shouldRunOnFunction(Function &F, ProfileSummaryInfo &PSI, in shouldRunOnFunction() argument
27 if (!PSI.hasProfileSummary()) in shouldRunOnFunction()
30 return PSI.isFunctionColdInCallGraph(&F, BFI); in shouldRunOnFunction()
37 ProfileSummaryInfo &PSI = AM.getResult<ProfileSummaryAnalysis>(M); in run() local
42 if (!shouldRunOnFunction(F, PSI, FAM)) in run()
H A DLowerAllowCheckPass.cpp75 const ProfileSummaryInfo *PSI, in removeUbsanTraps() argument
103 (PSI && PSI->isHotCountNthPercentile( in removeUbsanTraps()
156 ProfileSummaryInfo *PSI = in run() local
162 return removeUbsanTraps(F, BFI, PSI, ORE, Opts) in run()
/freebsd/contrib/llvm-project/llvm/lib/Transforms/IPO/
H A DAlwaysInliner.cpp34 Module &M, bool InsertLifetime, ProfileSummaryInfo &PSI, in AlwaysInlineImpl() argument
64 InlineFunctionInfo IFI(GetAssumptionCache, &PSI, nullptr, nullptr); in AlwaysInlineImpl()
132 auto &PSI = getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnModule() local
140 return AlwaysInlineImpl(M, InsertLifetime, PSI, /*FAM=*/nullptr, in runOnModule()
178 auto &PSI = MAM.getResult<ProfileSummaryAnalysis>(M); in run() local
180 bool Changed = AlwaysInlineImpl(M, InsertLifetime, PSI, &FAM, in run()
/freebsd/contrib/llvm-project/llvm/include/llvm/CodeGen/
H A DCalcSpillWeights.h51 ProfileSummaryInfo *PSI; variable
62 ProfileSummaryInfo *PSI = nullptr)
63 : MF(MF), LIS(LIS), VRM(VRM), Loops(Loops), PSI(PSI), MBFI(MBFI) {} in MF()
H A DMachineSizeOpts.h30 shouldOptimizeForSize(const MachineFunction *MF, ProfileSummaryInfo *PSI,
36 shouldOptimizeForSize(const MachineBasicBlock *MBB, ProfileSummaryInfo *PSI,
42 shouldOptimizeForSize(const MachineBasicBlock *MBB, ProfileSummaryInfo *PSI,
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Scalar/
H A DLoopLoadElimination.cpp172 ProfileSummaryInfo* PSI) in LoadEliminationForLoop() argument
173 : L(L), LI(LI), LAI(LAI), DT(DT), BFI(BFI), PSI(PSI), PSE(LAI.getPSE()) {} in LoadEliminationForLoop()
588 if (llvm::shouldOptimizeForSize(HeaderBB, PSI, BFI, in processLoop()
637 ProfileSummaryInfo *PSI; member in __anon087f49260311::LoadEliminationForLoop
646 ProfileSummaryInfo *PSI, in eliminateLoadsAcrossLoops() argument
672 LoadEliminationForLoop LEL(L, &LI, LAIs.getInfo(*L), &DT, BFI, PSI); in eliminateLoadsAcrossLoops()
691 auto *PSI = MAMProxy.getCachedResult<ProfileSummaryAnalysis>(*F.getParent()); in run() local
692 auto *BFI = (PSI && PSI->hasProfileSummary()) ? in run()
696 bool Changed = eliminateLoadsAcrossLoops(F, LI, DT, BFI, PSI, &SE, &AC, LAIs); in run()
/freebsd/contrib/llvm-project/llvm/lib/Analysis/
H A DStaticDataProfileInfo.cpp32 const Constant *C, const ProfileSummaryInfo *PSI) const { in getConstantSectionPrefix()
38 if (PSI->isHotCount(*Count)) in getConstantSectionPrefix()
46 if (PSI->isColdCount(*Count)) in getConstantSectionPrefix()
H A DOptimizationRemarkEmitter.cpp104 if (ProfileSummaryInfo *PSI = in runOnFunction() local
107 PSI->getOrCompHotCountThreshold()); in runOnFunction()
136 if (ProfileSummaryInfo *PSI = in run() local
139 PSI->getOrCompHotCountThreshold()); in run()
H A DProfileSummaryInfo.cpp234 PSI.reset(new ProfileSummaryInfo(M)); in doInitialization()
239 PSI.reset(); in doFinalization()
251 ProfileSummaryInfo &PSI = AM.getResult<ProfileSummaryAnalysis>(M); in run() local
256 if (PSI.isFunctionEntryHot(&F)) in run()
258 else if (PSI.isFunctionEntryCold(&F)) in run()
H A DInlineCost.cpp263 ProfileSummaryInfo *PSI; member in __anon463f3bdb0111::CallAnalyzer
528 ProfileSummaryInfo *PSI = nullptr, in CallAnalyzer() argument
533 GetTLI(GetTLI), PSI(PSI), F(Callee), DL(F.getDataLayout()), ORE(ORE), in CallAnalyzer()
745 GetAssumptionCache, GetBFI, GetTLI, PSI, ORE, in onLoweredCall()
896 if (!PSI || !PSI->hasProfileSummary()) in isCostBenefitAnalysisEnabled()
908 if (!PSI->hasInstrumentationProfile()) in isCostBenefitAnalysisEnabled()
921 if (!PSI->isHotCallSite(CandidateCall, CallerBFI)) in isCostBenefitAnalysisEnabled()
1063 APInt Threshold(128, PSI->getOrCompHotCountThreshold()); in costBenefitAnalysis()
1208 ProfileSummaryInfo *PSI = nullptr, in InlineCostCallAnalyzer() argument
1213 : CallAnalyzer(Callee, Call, TTI, GetAssumptionCache, GetBFI, GetTLI, PSI, in InlineCostCallAnalyzer()
[all …]
H A DModuleSummaryAnalysis.cpp168 ProfileSummaryInfo *PSI) { in getHotness() argument
169 if (!PSI) in getHotness()
171 if (PSI->isHotCount(ProfileCount)) in getHotness()
173 if (PSI->isColdCount(ProfileCount)) in getHotness()
307 BlockFrequencyInfo *BFI, ProfileSummaryInfo *PSI, DominatorTree &DT, in computeFunctionSummary() argument
443 auto ScaledCount = PSI->getProfileCount(*CB, BFI); in computeFunctionSummary()
444 auto Hotness = ScaledCount ? getHotness(*ScaledCount, PSI) in computeFunctionSummary()
501 .updateHotness(getHotness(Candidate.Count, PSI)); in computeFunctionSummary()
618 if (PSI->hasPartialSampleProfile() && ScalePartialSampleProfileWorkingSetSize) in computeFunctionSummary()
937 ProfileSummaryInfo *PSI, in buildModuleSummaryIndex() argument
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Target/X86/
H A DX86PadShortFunction.cpp115 auto *PSI = in runOnMachineFunction() local
117 auto *MBFI = (PSI && PSI->hasProfileSummary()) ? in runOnMachineFunction()
133 if (llvm::shouldOptimizeForSize(MBB, PSI, MBFI)) in runOnMachineFunction()
H A DX86FixupBWInsts.cpp143 ProfileSummaryInfo *PSI = nullptr; member in __anon46e815f70111::FixupBWInstPass
160 PSI = &getAnalysis<ProfileSummaryInfoWrapperPass>().getPSI(); in runOnMachineFunction()
161 MBFI = (PSI && PSI->hasProfileSummary()) ? in runOnMachineFunction()
445 OptForSize = llvm::shouldOptimizeForSize(&MBB, PSI, MBFI); in processBasicBlock()
/freebsd/contrib/llvm-project/llvm/include/llvm/Analysis/
H A DInlineCost.h284 ProfileSummaryInfo *PSI = nullptr, OptimizationRemarkEmitter *ORE = nullptr,
299 ProfileSummaryInfo *PSI = nullptr, OptimizationRemarkEmitter *ORE = nullptr,
326 ProfileSummaryInfo *PSI = nullptr,
336 ProfileSummaryInfo *PSI = nullptr,

12345