clang 17.0.0git
Public Member Functions | Protected Attributes | List of all members
clang::CodeGen::ABIInfo Class Referenceabstract

ABIInfo - Target specific hooks for defining how a type should be passed or returned from functions. More...

#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/CodeGen/ABIInfo.h"

Public Member Functions

 ABIInfo (CodeGen::CodeGenTypes &cgt)
 
virtual ~ABIInfo ()
 
virtual bool allowBFloatArgsAndRet () const
 
CodeGen::CGCXXABIgetCXXABI () const
 
ASTContextgetContext () const
 
llvm::LLVMContext & getVMContext () const
 
const llvm::DataLayout & getDataLayout () const
 
const TargetInfogetTarget () const
 
const CodeGenOptionsgetCodeGenOpts () const
 
llvm::CallingConv::ID getRuntimeCC () const
 Return the calling convention to use for system runtime functions.
 
virtual void computeInfo (CodeGen::CGFunctionInfo &FI) const =0
 
virtual CodeGen::Address EmitVAArg (CodeGen::CodeGenFunction &CGF, CodeGen::Address VAListAddr, QualType Ty) const =0
 EmitVAArg - Emit the target dependent code to load a value of.
 
bool isAndroid () const
 
bool isOHOSFamily () const
 
virtual CodeGen::Address EmitMSVAArg (CodeGen::CodeGenFunction &CGF, CodeGen::Address VAListAddr, QualType Ty) const
 Emit the target dependent code to load a value of.
 
virtual bool isHomogeneousAggregateBaseType (QualType Ty) const
 
virtual bool isHomogeneousAggregateSmallEnough (const Type *Base, uint64_t Members) const
 
virtual bool isZeroLengthBitfieldPermittedInHomogeneousAggregate () const
 
bool isHomogeneousAggregate (QualType Ty, const Type *&Base, uint64_t &Members) const
 isHomogeneousAggregate - Return true if a type is an ELFv2 homogeneous aggregate.
 
bool isPromotableIntegerTypeForABI (QualType Ty) const
 
CodeGen::ABIArgInfo getNaturalAlignIndirect (QualType Ty, bool ByVal=true, bool Realign=false, llvm::Type *Padding=nullptr) const
 A convenience method to return an indirect ABIArgInfo with an expected alignment equal to the ABI alignment of the given type.
 
CodeGen::ABIArgInfo getNaturalAlignIndirectInReg (QualType Ty, bool Realign=false) const
 

Protected Attributes

CodeGen::CodeGenTypesCGT
 
llvm::CallingConv::ID RuntimeCC
 

Detailed Description

ABIInfo - Target specific hooks for defining how a type should be passed or returned from functions.

Definition at line 44 of file ABIInfo.h.

Constructor & Destructor Documentation

◆ ABIInfo()

clang::CodeGen::ABIInfo::ABIInfo ( CodeGen::CodeGenTypes cgt)
inline

Definition at line 50 of file ABIInfo.h.

◆ ~ABIInfo()

ABIInfo::~ABIInfo ( )
virtualdefault

Member Function Documentation

◆ allowBFloatArgsAndRet()

virtual bool clang::CodeGen::ABIInfo::allowBFloatArgsAndRet ( ) const
inlinevirtual

Definition at line 55 of file ABIInfo.h.

◆ computeInfo()

virtual void clang::CodeGen::ABIInfo::computeInfo ( CodeGen::CGFunctionInfo FI) const
pure virtual

◆ EmitMSVAArg()

Address ABIInfo::EmitMSVAArg ( CodeGen::CodeGenFunction CGF,
CodeGen::Address  VAListAddr,
QualType  Ty 
) const
virtual

Emit the target dependent code to load a value of.

  • Ty from the __builtin_ms_va_list pointed to by
  • VAListAddr.

Definition at line 99 of file TargetInfo.cpp.

References clang::CodeGen::Address::invalid().

◆ EmitVAArg()

virtual CodeGen::Address clang::CodeGen::ABIInfo::EmitVAArg ( CodeGen::CodeGenFunction CGF,
CodeGen::Address  VAListAddr,
QualType  Ty 
) const
pure virtual

EmitVAArg - Emit the target dependent code to load a value of.

  • Ty from the va_list pointed to by
  • VAListAddr.

◆ getCodeGenOpts()

const CodeGenOptions & ABIInfo::getCodeGenOpts ( ) const

Definition at line 233 of file TargetInfo.cpp.

References CGT, and clang::CodeGen::CodeGenTypes::getCodeGenOpts().

◆ getContext()

ASTContext & ABIInfo::getContext ( ) const

◆ getCXXABI()

CGCXXABI & ABIInfo::getCXXABI ( ) const

Definition at line 213 of file TargetInfo.cpp.

References CGT, and clang::CodeGen::CodeGenTypes::getCXXABI().

Referenced by isHomogeneousAggregate().

◆ getDataLayout()

const llvm::DataLayout & ABIInfo::getDataLayout ( ) const

Definition at line 225 of file TargetInfo.cpp.

References CGT, and clang::CodeGen::CodeGenTypes::getDataLayout().

◆ getNaturalAlignIndirect()

ABIArgInfo ABIInfo::getNaturalAlignIndirect ( QualType  Ty,
bool  ByVal = true,
bool  Realign = false,
llvm::Type *  Padding = nullptr 
) const

A convenience method to return an indirect ABIArgInfo with an expected alignment equal to the ABI alignment of the given type.

Definition at line 86 of file TargetInfo.cpp.

References getContext(), and clang::CodeGen::ABIArgInfo::getIndirect().

Referenced by classifyReturnType().

◆ getNaturalAlignIndirectInReg()

ABIArgInfo ABIInfo::getNaturalAlignIndirectInReg ( QualType  Ty,
bool  Realign = false 
) const

Definition at line 94 of file TargetInfo.cpp.

References getContext(), and clang::CodeGen::ABIArgInfo::getIndirectInReg().

◆ getRuntimeCC()

llvm::CallingConv::ID clang::CodeGen::ABIInfo::getRuntimeCC ( ) const
inline

Return the calling convention to use for system runtime functions.

Definition at line 66 of file ABIInfo.h.

References RuntimeCC.

◆ getTarget()

const TargetInfo & ABIInfo::getTarget ( ) const

Definition at line 229 of file TargetInfo.cpp.

References CGT, and clang::CodeGen::CodeGenTypes::getTarget().

Referenced by isAndroid(), and isOHOSFamily().

◆ getVMContext()

llvm::LLVMContext & ABIInfo::getVMContext ( ) const

Definition at line 221 of file TargetInfo.cpp.

References CGT, and clang::CodeGen::CodeGenTypes::getLLVMContext().

◆ isAndroid()

bool ABIInfo::isAndroid ( ) const

Definition at line 237 of file TargetInfo.cpp.

References getTarget(), and clang::TargetInfo::getTriple().

◆ isHomogeneousAggregate()

bool ABIInfo::isHomogeneousAggregate ( QualType  Ty,
const Type *&  Base,
uint64_t &  Members 
) const

◆ isHomogeneousAggregateBaseType()

bool ABIInfo::isHomogeneousAggregateBaseType ( QualType  Ty) const
virtual

Definition at line 243 of file TargetInfo.cpp.

Referenced by isHomogeneousAggregate().

◆ isHomogeneousAggregateSmallEnough()

bool ABIInfo::isHomogeneousAggregateSmallEnough ( const Type Base,
uint64_t  Members 
) const
virtual

Definition at line 247 of file TargetInfo.cpp.

Referenced by isHomogeneousAggregate().

◆ isOHOSFamily()

bool ABIInfo::isOHOSFamily ( ) const

Definition at line 239 of file TargetInfo.cpp.

References getTarget(), and clang::TargetInfo::getTriple().

◆ isPromotableIntegerTypeForABI()

bool ABIInfo::isPromotableIntegerTypeForABI ( QualType  Ty) const

Definition at line 109 of file TargetInfo.cpp.

References clang::Type::getAs(), and getContext().

◆ isZeroLengthBitfieldPermittedInHomogeneousAggregate()

bool ABIInfo::isZeroLengthBitfieldPermittedInHomogeneousAggregate ( ) const
virtual

Definition at line 252 of file TargetInfo.cpp.

References getContext(), and clang::ASTContext::getLangOpts().

Referenced by isHomogeneousAggregate().

Member Data Documentation

◆ CGT

CodeGen::CodeGenTypes& clang::CodeGen::ABIInfo::CGT
protected

Definition at line 46 of file ABIInfo.h.

Referenced by getCodeGenOpts(), getContext(), getCXXABI(), getDataLayout(), getTarget(), and getVMContext().

◆ RuntimeCC

llvm::CallingConv::ID clang::CodeGen::ABIInfo::RuntimeCC
protected

Definition at line 47 of file ABIInfo.h.

Referenced by getRuntimeCC().


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