class CGFunctionInfo

Declaration

class CGFunctionInfo : public Node, private TrailingObjects { /* full declaration omitted */ };

Description

CGFunctionInfo - Class to encapsulate the information about a function definition.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:546

Inherits from: FoldingSetBase::Node, TrailingObjects

Member Variables

private unsigned int CallingConvention
The LLVM::CallingConv to use for this function (as specified by the user).
private unsigned int EffectiveCallingConvention
The LLVM::CallingConv to actually use for this function, which may depend on the ABI.
private unsigned int ASTCallingConvention
The clang::CallingConv that this was originally created with.
private unsigned int InstanceMethod
Whether this is an instance method.
private unsigned int ChainCall
Whether this is a chain call.
private unsigned int CmseNSCall
Whether this function is a CMSE nonsecure call
private unsigned int NoReturn
Whether this function is noreturn.
private unsigned int ReturnsRetained
Whether this function is returns-retained.
private unsigned int NoCallerSavedRegs
Whether this function saved caller registers.
private unsigned int HasRegParm
How many arguments to pass inreg.
private unsigned int RegParm
private unsigned int NoCfCheck
Whether this function has nocf_check attribute.
private unsigned int MaxVectorWidth
Log 2 of the maximum vector width.
private clang::CodeGen::RequiredArgs Required
private llvm::StructType* ArgStruct
The struct representing all arguments passed in memory. Only used when passing non-trivial types with inalloca. Not part of the profile.
private unsigned int ArgStructAlign
private unsigned int HasExtParameterInfos
private unsigned int NumArgs

Method Overview

Inherited from FoldingSetBase::Node:

Methods

CGFunctionInfo()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:616

static void Profile(
    llvm::FoldingSetNodeID& ID,
    bool InstanceMethod,
    bool ChainCall,
    const FunctionType::ExtInfo& info,
    ArrayRef<clang::CodeGen::CGFunctionInfo::
                 ExtParameterInfo> paramInfos,
    clang::CodeGen::RequiredArgs required,
    clang::CanQualType resultType,
    ArrayRef<clang::CanQualType> argTypes)

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:769

Parameters

llvm::FoldingSetNodeID& ID
bool InstanceMethod
bool ChainCall
const FunctionType::ExtInfo& info
ArrayRef<clang::CodeGen::CGFunctionInfo:: ExtParameterInfo> paramInfos
clang::CodeGen::RequiredArgs required
clang::CanQualType resultType
ArrayRef<clang::CanQualType> argTypes

void Profile(llvm::FoldingSetNodeID& ID)

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:748

Parameters

llvm::FoldingSetNodeID& ID

clang::CodeGen::CGFunctionInfo::const_arg_iterator
arg_begin() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:649

clang::CodeGen::CGFunctionInfo::arg_iterator
arg_begin()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:651

clang::CodeGen::CGFunctionInfo::const_arg_iterator
arg_end() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:650

clang::CodeGen::CGFunctionInfo::arg_iterator
arg_end()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:652

unsigned int arg_size() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:654

MutableArrayRef<
    clang::CodeGen::CGFunctionInfo::ArgInfo>
arguments()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:642

ArrayRef<clang::CodeGen::CGFunctionInfo::ArgInfo>
arguments() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:645

static clang::CodeGen::CGFunctionInfo* create(
    unsigned int llvmCC,
    bool instanceMethod,
    bool chainCall,
    const FunctionType::ExtInfo& extInfo,
    ArrayRef<clang::CodeGen::CGFunctionInfo::
                 ExtParameterInfo> paramInfos,
    clang::CanQualType resultType,
    ArrayRef<clang::CanQualType> argTypes,
    clang::CodeGen::RequiredArgs required)

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:619

Parameters

unsigned int llvmCC
bool instanceMethod
bool chainCall
const FunctionType::ExtInfo& extInfo
ArrayRef<clang::CodeGen::CGFunctionInfo:: ExtParameterInfo> paramInfos
clang::CanQualType resultType
ArrayRef<clang::CanQualType> argTypes
clang::CodeGen::RequiredArgs required

clang::CallingConv getASTCallingConvention() const

Description

getASTCallingConvention() - Return the AST-specified calling convention.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:682

llvm::StructType* getArgStruct() const

Description

Get the struct type used to represent all the arguments in memory.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:728

clang::CharUnits getArgStructAlignment() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:729

const clang::CodeGen::CGFunctionInfo::ArgInfo*
getArgsBuffer() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:605

clang::CodeGen::CGFunctionInfo::ArgInfo*
getArgsBuffer()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:602

unsigned int getCallingConvention() const

Description

getCallingConvention - Return the user specified calling convention, which has been translated into an LLVM CC.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:688

unsigned int getEffectiveCallingConvention() const

Description

getEffectiveCallingConvention - Return the actual calling convention to use, which may depend on the ABI.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:692

FunctionType::ExtInfo getExtInfo() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:702

clang::CodeGen::CGFunctionInfo::ExtParameterInfo
getExtParameterInfo(unsigned int argIndex) const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:718

Parameters

unsigned int argIndex

ArrayRef<clang::CodeGen::CGFunctionInfo::
             ExtParameterInfo>
getExtParameterInfos() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:714

clang::CodeGen::CGFunctionInfo::ExtParameterInfo*
getExtParameterInfosBuffer()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:609

const clang::CodeGen::CGFunctionInfo::
    ExtParameterInfo*
    getExtParameterInfosBuffer() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:612

bool getHasRegParm() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:699

unsigned int getMaxVectorWidth() const

Description

Return the maximum vector width in the arguments.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:738

unsigned int getNumRequiredArgs() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:658

unsigned int getRegParm() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:700

clang::CodeGen::RequiredArgs getRequiredArgs()
    const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:657

clang::CodeGen::ABIArgInfo& getReturnInfo()

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:711

const clang::CodeGen::ABIArgInfo& getReturnInfo()
    const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:712

clang::CanQualType getReturnType() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:709

bool isChainCall() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:664

bool isCmseNSCall() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:666

bool isInstanceMethod() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:662

bool isNoCallerSavedRegs() const

Description

Whether this function no longer saves caller registers.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:675

bool isNoCfCheck() const

Description

Whether this function has nocf_check attribute.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:678

bool isNoReturn() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:668

bool isReturnsRetained() const

Description

In ARC, whether this function retains its return value. This is not always reliable for call sites.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:672

bool isVariadic() const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:656

size_t numTrailingObjects(
    OverloadToken<
        clang::CodeGen::CGFunctionInfo::ArgInfo>)
    const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:632

Parameters

OverloadToken< clang::CodeGen::CGFunctionInfo::ArgInfo>

size_t numTrailingObjects(
    OverloadToken<clang::CodeGen::CGFunctionInfo::
                      ExtParameterInfo>) const

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:635

Parameters

OverloadToken<clang::CodeGen::CGFunctionInfo:: ExtParameterInfo>

void setArgStruct(llvm::StructType* Ty,
                  clang::CharUnits Align)

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:732

Parameters

llvm::StructType* Ty
clang::CharUnits Align

void setEffectiveCallingConvention(
    unsigned int Value)

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:695

Parameters

unsigned int Value

void setMaxVectorWidth(unsigned int Width)

Description

Set the maximum vector width in the arguments.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:743

Parameters

unsigned int Width

bool usesInAlloca() const

Description

Return true if this function uses inalloca arguments.

Declared at: clang/include/clang/CodeGen/CGFunctionInfo.h:725