LLVM  14.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::MLInlineAdvice Class Reference

InlineAdvice that tracks changes post inlining. More...

#include "llvm/Analysis/MLInlineAdvisor.h"

Inheritance diagram for llvm::MLInlineAdvice:
Inheritance graph
Collaboration diagram for llvm::MLInlineAdvice:
Collaboration graph

Public Member Functions

 MLInlineAdvice (MLInlineAdvisor *Advisor, CallBase &CB, OptimizationRemarkEmitter &ORE, bool Recommendation)
virtual ~MLInlineAdvice ()=default
void recordInliningImpl () override
void recordInliningWithCalleeDeletedImpl () override
void recordUnsuccessfulInliningImpl (const InlineResult &Result) override
void recordUnattemptedInliningImpl () override
FunctiongetCaller () const
FunctiongetCallee () const
- Public Member Functions inherited from llvm::InlineAdvice
 InlineAdvice (InlineAdvisor *Advisor, CallBase &CB, OptimizationRemarkEmitter &ORE, bool IsInliningRecommended)
 InlineAdvice (InlineAdvice &&)=delete
 InlineAdvice (const InlineAdvice &)=delete
virtual ~InlineAdvice ()
void recordInlining ()
 Exactly one of the record* APIs must be called. More...
void recordInliningWithCalleeDeleted ()
 Call after inlining succeeded, and resulted in deleting the callee. More...
void recordUnsuccessfulInlining (const InlineResult &Result)
 Call after the decision for a call site was to not inline. More...
void recordUnattemptedInlining ()
 Call to indicate inlining was not attempted. More...
bool isInliningRecommended () const
 Get the inlining recommendation. More...
const DebugLocgetOriginalCallSiteDebugLoc () const
const BasicBlockgetOriginalCallSiteBasicBlock () const

Public Attributes

const int64_t CallerIRSize
const int64_t CalleeIRSize
const int64_t CallerAndCalleeEdges

Additional Inherited Members

- Protected Attributes inherited from llvm::InlineAdvice
InlineAdvisor *const Advisor
Function *const Caller
 Caller and Callee are pre-inlining. More...
Function *const Callee
const DebugLoc DLoc
const BasicBlock *const Block
const bool IsInliningRecommended

Detailed Description

InlineAdvice that tracks changes post inlining.

For that reason, it only overrides the "successful inlining" extension points.

Definition at line 71 of file MLInlineAdvisor.h.

Constructor & Destructor Documentation

◆ MLInlineAdvice()

llvm::MLInlineAdvice::MLInlineAdvice ( MLInlineAdvisor Advisor,
CallBase CB,
OptimizationRemarkEmitter ORE,
bool  Recommendation 

Definition at line 73 of file MLInlineAdvisor.h.

◆ ~MLInlineAdvice()

virtual llvm::MLInlineAdvice::~MLInlineAdvice ( )

Member Function Documentation

◆ getCallee()

Function* llvm::MLInlineAdvice::getCallee ( ) const

Definition at line 92 of file MLInlineAdvisor.h.

References llvm::InlineAdvice::Callee.

◆ getCaller()

Function* llvm::MLInlineAdvice::getCaller ( ) const

Definition at line 91 of file MLInlineAdvisor.h.

References llvm::InlineAdvice::Caller.

◆ recordInliningImpl()

void llvm::MLInlineAdvice::recordInliningImpl ( )

Reimplemented from llvm::InlineAdvice.

◆ recordInliningWithCalleeDeletedImpl()

void llvm::MLInlineAdvice::recordInliningWithCalleeDeletedImpl ( )

Reimplemented from llvm::InlineAdvice.

◆ recordUnattemptedInliningImpl()

void llvm::MLInlineAdvice::recordUnattemptedInliningImpl ( )

Reimplemented from llvm::InlineAdvice.

◆ recordUnsuccessfulInliningImpl()

void llvm::MLInlineAdvice::recordUnsuccessfulInliningImpl ( const InlineResult Result)

Reimplemented from llvm::InlineAdvice.

Member Data Documentation

◆ CalleeIRSize

const int64_t llvm::MLInlineAdvice::CalleeIRSize

Definition at line 95 of file MLInlineAdvisor.h.

◆ CallerAndCalleeEdges

const int64_t llvm::MLInlineAdvice::CallerAndCalleeEdges

Definition at line 96 of file MLInlineAdvisor.h.

◆ CallerIRSize

const int64_t llvm::MLInlineAdvice::CallerIRSize

Definition at line 94 of file MLInlineAdvisor.h.

The documentation for this class was generated from the following file: