LLVM 22.0.0git
ModuleInliner.cpp File Reference

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "module-inline"

Functions

 STATISTIC (NumInlined, "Number of functions inlined")
 STATISTIC (NumDeleted, "Number of functions deleted because all callers found")
static bool inlineHistoryIncludes (Function *F, int InlineHistoryID, const SmallVectorImpl< std::pair< Function *, int > > &InlineHistory)
 Return true if the specified inline history ID indicates an inline history that includes the specified function.
static bool isKnownLibFunction (Function &F, TargetLibraryInfo &TLI)

Variables

static cl::opt< boolCtxProfPromoteAlwaysInline ("ctx-prof-promote-alwaysinline", cl::init(false), cl::Hidden, cl::desc("If using a contextual profile in this module, and an indirect " "call target is marked as alwaysinline, perform indirect call " "promotion for that target. If multiple targets for an indirect " "call site fit this description, they are all promoted."))

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "module-inline"

Definition at line 47 of file ModuleInliner.cpp.

Function Documentation

◆ inlineHistoryIncludes()

bool inlineHistoryIncludes ( Function * F,
int InlineHistoryID,
const SmallVectorImpl< std::pair< Function *, int > > & InlineHistory )
static

Return true if the specified inline history ID indicates an inline history that includes the specified function.

Definition at line 61 of file ModuleInliner.cpp.

References assert(), and F.

◆ isKnownLibFunction()

bool isKnownLibFunction ( Function & F,
TargetLibraryInfo & TLI )
static

◆ STATISTIC() [1/2]

STATISTIC ( NumDeleted ,
"Number of functions deleted because all callers found"  )

◆ STATISTIC() [2/2]

STATISTIC ( NumInlined ,
"Number of functions inlined"  )

Variable Documentation

◆ CtxProfPromoteAlwaysInline

cl::opt< bool > CtxProfPromoteAlwaysInline("ctx-prof-promote-alwaysinline", cl::init(false), cl::Hidden, cl::desc("If using a contextual profile in this module, and an indirect " "call target is marked as alwaysinline, perform indirect call " "promotion for that target. If multiple targets for an indirect " "call site fit this description, they are all promoted.")) ( "ctx-prof-promote-alwaysinline" ,
cl::init(false) ,
cl::Hidden ,
cl::desc("If using a contextual profile in this module, and an indirect " "call target is marked as alwaysinline, perform indirect call " "promotion for that target. If multiple targets for an indirect " "call site fit this description, they are all promoted.")  )
static