LLVM  12.0.0git
Classes | Public Member Functions | List of all members
llvm::StackSafetyInfo Class Reference

Interface to access stack safety analysis results for single function. More...

#include "llvm/Analysis/StackSafetyAnalysis.h"

Classes

struct  InfoTy
 

Public Member Functions

 StackSafetyInfo ()
 
 StackSafetyInfo (Function *F, std::function< ScalarEvolution &()> GetSE)
 
 StackSafetyInfo (StackSafetyInfo &&)
 
StackSafetyInfooperator= (StackSafetyInfo &&)
 
 ~StackSafetyInfo ()
 
const InfoTygetInfo () const
 
void print (raw_ostream &O) const
 
std::vector< FunctionSummary::ParamAccessgetParamAccesses () const
 Parameters use for a FunctionSummary. More...
 

Detailed Description

Interface to access stack safety analysis results for single function.

Definition at line 26 of file StackSafetyAnalysis.h.

Constructor & Destructor Documentation

◆ StackSafetyInfo() [1/3]

StackSafetyInfo::StackSafetyInfo ( )
default

Referenced by StackSafetyInfo().

◆ StackSafetyInfo() [2/3]

StackSafetyInfo::StackSafetyInfo ( Function F,
std::function< ScalarEvolution &()>  GetSE 
)

Definition at line 702 of file StackSafetyAnalysis.cpp.

References operator=(), StackSafetyInfo(), and ~StackSafetyInfo().

◆ StackSafetyInfo() [3/3]

StackSafetyInfo::StackSafetyInfo ( StackSafetyInfo &&  )
default

◆ ~StackSafetyInfo()

StackSafetyInfo::~StackSafetyInfo ( )
default

Referenced by StackSafetyInfo().

Member Function Documentation

◆ getInfo()

const StackSafetyInfo::InfoTy & StackSafetyInfo::getInfo ( ) const

Definition at line 712 of file StackSafetyAnalysis.cpp.

Referenced by getParamAccesses(), and print().

◆ getParamAccesses()

std::vector< FunctionSummary::ParamAccess > StackSafetyInfo::getParamAccesses ( ) const

Parameters use for a FunctionSummary.

Function collects access information of all pointer parameters. Information includes a range of direct access of parameters by the functions and all call sites accepting the parameter. StackSafety assumes that missing parameter information means possibility of access to the parameter with any offset, so we can correctly link code without StackSafety information, e.g. non-ThinLTO.

Definition at line 752 of file StackSafetyAnalysis.cpp.

References C, llvm::FunctionSummary::ParamAccess::Calls, getInfo(), and llvm::StackSafetyGlobalInfo::StackSafetyGlobalInfo().

◆ operator=()

StackSafetyInfo & StackSafetyInfo::operator= ( StackSafetyInfo &&  )
default

Referenced by StackSafetyInfo().

◆ print()

void StackSafetyInfo::print ( raw_ostream O) const

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