Lines Matching defs:IC

205     const ReplayInlinerSettings &ReplaySettings, InlineContext IC) {
209 Advisor.reset(DA.Factory(M, FAM, Params, IC));
219 Advisor.reset(new DefaultInlineAdvisor(M, FAM, Params, IC));
225 /* EmitRemarks =*/true, IC);
244 /// inlined which is proved to be more beneficial. \p IC is the
250 InlineCost IC, int &TotalSecondaryCost,
258 if (IC.getCost() <= 0)
278 int CandidateCost = IC.getCost() - 1;
326 // inlining -- IC.getCost() multiplied by the number of callers to Caller.
328 return TotalSecondaryCost < IC.getCost();
330 int TotalCost = TotalSecondaryCost + IC.getCost() * NumCallerUsers;
331 int Allowance = IC.getCost() * InlineDeferralScale;
341 RemarkT &operator<<(RemarkT &&R, const InlineCost &IC) {
343 if (IC.isAlways()) {
345 } else if (IC.isNever()) {
348 R << "(cost=" << ore::NV("Cost", IC.getCost())
349 << ", threshold=" << ore::NV("Threshold", IC.getThreshold()) << ")";
351 if (const char *Reason = IC.getReason())
357 std::string llvm::inlineCostStr(const InlineCost &IC) {
360 Remark << IC;
382 InlineCost IC = GetInlineCost(CB);
387 if (IC.isAlways()) {
388 LLVM_DEBUG(dbgs() << " Inlining " << inlineCostStr(IC)
390 return IC;
393 if (!IC) {
394 LLVM_DEBUG(dbgs() << " NOT Inlining " << inlineCostStr(IC)
396 if (IC.isNever()) {
401 << "' because it should never be inlined " << IC;
408 << IC;
411 setInlineRemark(CB, inlineCostStr(IC));
416 if (EnableDeferral && shouldBeDeferred(Caller, CalleeTTI, IC,
419 << " Cost = " << IC.getCost()
432 LLVM_DEBUG(dbgs() << " Inlining " << inlineCostStr(IC) << ", Call: " << CB
434 return IC;
511 const Function &Callee, const Function &Caller, const InlineCost &IC,
514 ORE, DLoc, Block, Callee, Caller, IC.isAlways(),
518 Remark << " with " << IC;
524 std::optional<InlineContext> IC)
525 : M(M), FAM(FAM), IC(IC),
526 AnnotatedInlinePassName((IC && AnnotateInlinePhase)
527 ? llvm::AnnotateInlinePassName(*IC)
587 std::string llvm::AnnotateInlinePassName(InlineContext IC) {
588 return std::string(getLTOPhase(IC.LTOPhase)) + "-" +
589 std::string(getInlineAdvisorContext(IC.Pass));