LLVM 20.0.0git
|
#include "llvm/IR/DIBuilder.h"
Public Member Functions | |
DIBuilder (Module &M, bool AllowUnresolved=true, DICompileUnit *CU=nullptr) | |
Construct a builder for a module. | |
DIBuilder (const DIBuilder &)=delete | |
DIBuilder & | operator= (const DIBuilder &)=delete |
void | finalize () |
Construct any deferred debug info descriptors. | |
void | finalizeSubprogram (DISubprogram *SP) |
Finalize a specific subprogram - no new variables may be added to this subprogram afterwards. | |
DICompileUnit * | createCompileUnit (unsigned Lang, DIFile *File, StringRef Producer, bool isOptimized, StringRef Flags, unsigned RV, StringRef SplitName=StringRef(), DICompileUnit::DebugEmissionKind Kind=DICompileUnit::DebugEmissionKind::FullDebug, uint64_t DWOId=0, bool SplitDebugInlining=true, bool DebugInfoForProfiling=false, DICompileUnit::DebugNameTableKind NameTableKind=DICompileUnit::DebugNameTableKind::Default, bool RangesBaseAddress=false, StringRef SysRoot={}, StringRef SDK={}) |
A CompileUnit provides an anchor for all debugging information generated during this instance of compilation. | |
DIFile * | createFile (StringRef Filename, StringRef Directory, std::optional< DIFile::ChecksumInfo< StringRef > > Checksum=std::nullopt, std::optional< StringRef > Source=std::nullopt) |
Create a file descriptor to hold debugging information for a file. | |
DIMacro * | createMacro (DIMacroFile *Parent, unsigned Line, unsigned MacroType, StringRef Name, StringRef Value=StringRef()) |
Create debugging information entry for a macro. | |
DIMacroFile * | createTempMacroFile (DIMacroFile *Parent, unsigned Line, DIFile *File) |
Create debugging information temporary entry for a macro file. | |
DIEnumerator * | createEnumerator (StringRef Name, const APSInt &Value) |
Create a single enumerator value. | |
DIEnumerator * | createEnumerator (StringRef Name, uint64_t Val, bool IsUnsigned=false) |
DIBasicType * | createUnspecifiedType (StringRef Name) |
Create a DWARF unspecified type. | |
DIBasicType * | createNullPtrType () |
Create C++11 nullptr type. | |
DIBasicType * | createBasicType (StringRef Name, uint64_t SizeInBits, unsigned Encoding, DINode::DIFlags Flags=DINode::FlagZero, uint32_t NumExtraInhabitants=0) |
Create debugging information entry for a basic type. | |
DIStringType * | createStringType (StringRef Name, uint64_t SizeInBits) |
Create debugging information entry for a string type. | |
DIStringType * | createStringType (StringRef Name, DIVariable *StringLength, DIExpression *StrLocationExp=nullptr) |
Create debugging information entry for Fortran assumed length string type. | |
DIStringType * | createStringType (StringRef Name, DIExpression *StringLengthExp, DIExpression *StrLocationExp=nullptr) |
Create debugging information entry for Fortran assumed length string type. | |
DIDerivedType * | createQualifiedType (unsigned Tag, DIType *FromTy) |
Create debugging information entry for a qualified type, e.g. | |
DIDerivedType * | createPointerType (DIType *PointeeTy, uint64_t SizeInBits, uint32_t AlignInBits=0, std::optional< unsigned > DWARFAddressSpace=std::nullopt, StringRef Name="", DINodeArray Annotations=nullptr) |
Create debugging information entry for a pointer. | |
DIDerivedType * | createPtrAuthQualifiedType (DIType *FromTy, unsigned Key, bool IsAddressDiscriminated, unsigned ExtraDiscriminator, bool IsaPointer, bool authenticatesNullValues) |
Create a __ptrauth qualifier. | |
DIDerivedType * | createMemberPointerType (DIType *PointeeTy, DIType *Class, uint64_t SizeInBits, uint32_t AlignInBits=0, DINode::DIFlags Flags=DINode::FlagZero) |
Create debugging information entry for a pointer to member. | |
DIDerivedType * | createReferenceType (unsigned Tag, DIType *RTy, uint64_t SizeInBits=0, uint32_t AlignInBits=0, std::optional< unsigned > DWARFAddressSpace=std::nullopt) |
Create debugging information entry for a c++ style reference or rvalue reference type. | |
DIDerivedType * | createTypedef (DIType *Ty, StringRef Name, DIFile *File, unsigned LineNo, DIScope *Context, uint32_t AlignInBits=0, DINode::DIFlags Flags=DINode::FlagZero, DINodeArray Annotations=nullptr) |
Create debugging information entry for a typedef. | |
DIDerivedType * | createTemplateAlias (DIType *Ty, StringRef Name, DIFile *File, unsigned LineNo, DIScope *Context, DINodeArray TParams, uint32_t AlignInBits=0, DINode::DIFlags Flags=DINode::FlagZero, DINodeArray Annotations=nullptr) |
Create debugging information entry for a template alias. | |
DIDerivedType * | createFriend (DIType *Ty, DIType *FriendTy) |
Create debugging information entry for a 'friend'. | |
DIDerivedType * | createInheritance (DIType *Ty, DIType *BaseTy, uint64_t BaseOffset, uint32_t VBPtrOffset, DINode::DIFlags Flags) |
Create debugging information entry to establish inheritance relationship between two types. | |
DIDerivedType * | createMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint32_t AlignInBits, uint64_t OffsetInBits, DINode::DIFlags Flags, DIType *Ty, DINodeArray Annotations=nullptr) |
Create debugging information entry for a member. | |
DIDerivedType * | createVariantMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint32_t AlignInBits, uint64_t OffsetInBits, Constant *Discriminant, DINode::DIFlags Flags, DIType *Ty) |
Create debugging information entry for a variant. | |
DIDerivedType * | createBitFieldMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint64_t OffsetInBits, uint64_t StorageOffsetInBits, DINode::DIFlags Flags, DIType *Ty, DINodeArray Annotations=nullptr) |
Create debugging information entry for a bit field member. | |
DIDerivedType * | createStaticMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, DIType *Ty, DINode::DIFlags Flags, Constant *Val, unsigned Tag, uint32_t AlignInBits=0) |
Create debugging information entry for a C++ static data member. | |
DIDerivedType * | createObjCIVar (StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint32_t AlignInBits, uint64_t OffsetInBits, DINode::DIFlags Flags, DIType *Ty, MDNode *PropertyNode) |
Create debugging information entry for Objective-C instance variable. | |
DIObjCProperty * | createObjCProperty (StringRef Name, DIFile *File, unsigned LineNumber, StringRef GetterName, StringRef SetterName, unsigned PropertyAttributes, DIType *Ty) |
Create debugging information entry for Objective-C property. | |
DICompositeType * | createClassType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber, uint64_t SizeInBits, uint32_t AlignInBits, uint64_t OffsetInBits, DINode::DIFlags Flags, DIType *DerivedFrom, DINodeArray Elements, unsigned RunTimeLang=0, DIType *VTableHolder=nullptr, MDNode *TemplateParms=nullptr, StringRef UniqueIdentifier="") |
Create debugging information entry for a class. | |
DICompositeType * | createStructType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber, uint64_t SizeInBits, uint32_t AlignInBits, DINode::DIFlags Flags, DIType *DerivedFrom, DINodeArray Elements, unsigned RunTimeLang=0, DIType *VTableHolder=nullptr, StringRef UniqueIdentifier="", DIType *Specification=nullptr, uint32_t NumExtraInhabitants=0) |
Create debugging information entry for a struct. | |
DICompositeType * | createUnionType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber, uint64_t SizeInBits, uint32_t AlignInBits, DINode::DIFlags Flags, DINodeArray Elements, unsigned RunTimeLang=0, StringRef UniqueIdentifier="") |
Create debugging information entry for an union. | |
DICompositeType * | createVariantPart (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber, uint64_t SizeInBits, uint32_t AlignInBits, DINode::DIFlags Flags, DIDerivedType *Discriminator, DINodeArray Elements, StringRef UniqueIdentifier="") |
Create debugging information entry for a variant part. | |
DITemplateTypeParameter * | createTemplateTypeParameter (DIScope *Scope, StringRef Name, DIType *Ty, bool IsDefault) |
Create debugging information for template type parameter. | |
DITemplateValueParameter * | createTemplateValueParameter (DIScope *Scope, StringRef Name, DIType *Ty, bool IsDefault, Constant *Val) |
Create debugging information for template value parameter. | |
DITemplateValueParameter * | createTemplateTemplateParameter (DIScope *Scope, StringRef Name, DIType *Ty, StringRef Val, bool IsDefault=false) |
Create debugging information for a template template parameter. | |
DITemplateValueParameter * | createTemplateParameterPack (DIScope *Scope, StringRef Name, DIType *Ty, DINodeArray Val) |
Create debugging information for a template parameter pack. | |
DICompositeType * | createArrayType (uint64_t Size, uint32_t AlignInBits, DIType *Ty, DINodeArray Subscripts, PointerUnion< DIExpression *, DIVariable * > DataLocation=nullptr, PointerUnion< DIExpression *, DIVariable * > Associated=nullptr, PointerUnion< DIExpression *, DIVariable * > Allocated=nullptr, PointerUnion< DIExpression *, DIVariable * > Rank=nullptr) |
Create debugging information entry for an array. | |
DICompositeType * | createVectorType (uint64_t Size, uint32_t AlignInBits, DIType *Ty, DINodeArray Subscripts) |
Create debugging information entry for a vector type. | |
DICompositeType * | createEnumerationType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber, uint64_t SizeInBits, uint32_t AlignInBits, DINodeArray Elements, DIType *UnderlyingType, unsigned RunTimeLang=0, StringRef UniqueIdentifier="", bool IsScoped=false) |
Create debugging information entry for an enumeration. | |
DIDerivedType * | createSetType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint32_t AlignInBits, DIType *Ty) |
Create debugging information entry for a set. | |
DISubroutineType * | createSubroutineType (DITypeRefArray ParameterTypes, DINode::DIFlags Flags=DINode::FlagZero, unsigned CC=0) |
Create subroutine type. | |
DICompositeType * | createForwardDecl (unsigned Tag, StringRef Name, DIScope *Scope, DIFile *F, unsigned Line, unsigned RuntimeLang=0, uint64_t SizeInBits=0, uint32_t AlignInBits=0, StringRef UniqueIdentifier="") |
Create a permanent forward-declared type. | |
DICompositeType * | createReplaceableCompositeType (unsigned Tag, StringRef Name, DIScope *Scope, DIFile *F, unsigned Line, unsigned RuntimeLang=0, uint64_t SizeInBits=0, uint32_t AlignInBits=0, DINode::DIFlags Flags=DINode::FlagFwdDecl, StringRef UniqueIdentifier="", DINodeArray Annotations=nullptr) |
Create a temporary forward-declared type. | |
void | retainType (DIScope *T) |
Retain DIScope* in a module even if it is not referenced through debug info anchors. | |
DIBasicType * | createUnspecifiedParameter () |
Create unspecified parameter type for a subroutine type. | |
DINodeArray | getOrCreateArray (ArrayRef< Metadata * > Elements) |
Get a DINodeArray, create one if required. | |
DIMacroNodeArray | getOrCreateMacroArray (ArrayRef< Metadata * > Elements) |
Get a DIMacroNodeArray, create one if required. | |
DITypeRefArray | getOrCreateTypeArray (ArrayRef< Metadata * > Elements) |
Get a DITypeRefArray, create one if required. | |
DISubrange * | getOrCreateSubrange (int64_t Lo, int64_t Count) |
Create a descriptor for a value range. | |
DISubrange * | getOrCreateSubrange (int64_t Lo, Metadata *CountNode) |
DISubrange * | getOrCreateSubrange (Metadata *Count, Metadata *LowerBound, Metadata *UpperBound, Metadata *Stride) |
DIGenericSubrange * | getOrCreateGenericSubrange (DIGenericSubrange::BoundType Count, DIGenericSubrange::BoundType LowerBound, DIGenericSubrange::BoundType UpperBound, DIGenericSubrange::BoundType Stride) |
DIGlobalVariableExpression * | createGlobalVariableExpression (DIScope *Context, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DIType *Ty, bool IsLocalToUnit, bool isDefined=true, DIExpression *Expr=nullptr, MDNode *Decl=nullptr, MDTuple *TemplateParams=nullptr, uint32_t AlignInBits=0, DINodeArray Annotations=nullptr) |
Create a new descriptor for the specified variable. | |
DIGlobalVariable * | createTempGlobalVariableFwdDecl (DIScope *Context, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DIType *Ty, bool IsLocalToUnit, MDNode *Decl=nullptr, MDTuple *TemplateParams=nullptr, uint32_t AlignInBits=0) |
Identical to createGlobalVariable except that the resulting DbgNode is temporary and meant to be RAUWed. | |
DILocalVariable * | createAutoVariable (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, DIType *Ty, bool AlwaysPreserve=false, DINode::DIFlags Flags=DINode::FlagZero, uint32_t AlignInBits=0) |
Create a new descriptor for an auto variable. | |
DILabel * | createLabel (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, bool AlwaysPreserve=false) |
Create a new descriptor for an label. | |
DILocalVariable * | createParameterVariable (DIScope *Scope, StringRef Name, unsigned ArgNo, DIFile *File, unsigned LineNo, DIType *Ty, bool AlwaysPreserve=false, DINode::DIFlags Flags=DINode::FlagZero, DINodeArray Annotations=nullptr) |
Create a new descriptor for a parameter variable. | |
DIExpression * | createExpression (ArrayRef< uint64_t > Addr={}) |
Create a new descriptor for the specified variable which has a complex address expression for its address. | |
DIExpression * | createConstantValueExpression (uint64_t Val) |
Create an expression for a variable that does not have an address, but does have a constant value. | |
DISubprogram * | createFunction (DIScope *Scope, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DISubroutineType *Ty, unsigned ScopeLine, DINode::DIFlags Flags=DINode::FlagZero, DISubprogram::DISPFlags SPFlags=DISubprogram::SPFlagZero, DITemplateParameterArray TParams=nullptr, DISubprogram *Decl=nullptr, DITypeArray ThrownTypes=nullptr, DINodeArray Annotations=nullptr, StringRef TargetFuncName="") |
Create a new descriptor for the specified subprogram. | |
DISubprogram * | createTempFunctionFwdDecl (DIScope *Scope, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DISubroutineType *Ty, unsigned ScopeLine, DINode::DIFlags Flags=DINode::FlagZero, DISubprogram::DISPFlags SPFlags=DISubprogram::SPFlagZero, DITemplateParameterArray TParams=nullptr, DISubprogram *Decl=nullptr, DITypeArray ThrownTypes=nullptr) |
Identical to createFunction, except that the resulting DbgNode is meant to be RAUWed. | |
DISubprogram * | createMethod (DIScope *Scope, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DISubroutineType *Ty, unsigned VTableIndex=0, int ThisAdjustment=0, DIType *VTableHolder=nullptr, DINode::DIFlags Flags=DINode::FlagZero, DISubprogram::DISPFlags SPFlags=DISubprogram::SPFlagZero, DITemplateParameterArray TParams=nullptr, DITypeArray ThrownTypes=nullptr) |
Create a new descriptor for the specified C++ method. | |
DICommonBlock * | createCommonBlock (DIScope *Scope, DIGlobalVariable *decl, StringRef Name, DIFile *File, unsigned LineNo) |
Create common block entry for a Fortran common block. | |
DINamespace * | createNameSpace (DIScope *Scope, StringRef Name, bool ExportSymbols) |
This creates new descriptor for a namespace with the specified parent scope. | |
DIModule * | createModule (DIScope *Scope, StringRef Name, StringRef ConfigurationMacros, StringRef IncludePath, StringRef APINotesFile={}, DIFile *File=nullptr, unsigned LineNo=0, bool IsDecl=false) |
This creates new descriptor for a module with the specified parent scope. | |
DILexicalBlockFile * | createLexicalBlockFile (DIScope *Scope, DIFile *File, unsigned Discriminator=0) |
This creates a descriptor for a lexical block with a new file attached. | |
DILexicalBlock * | createLexicalBlock (DIScope *Scope, DIFile *File, unsigned Line, unsigned Col) |
This creates a descriptor for a lexical block with the specified parent context. | |
DIImportedEntity * | createImportedModule (DIScope *Context, DINamespace *NS, DIFile *File, unsigned Line, DINodeArray Elements=nullptr) |
Create a descriptor for an imported module. | |
DIImportedEntity * | createImportedModule (DIScope *Context, DIImportedEntity *NS, DIFile *File, unsigned Line, DINodeArray Elements=nullptr) |
Create a descriptor for an imported module. | |
DIImportedEntity * | createImportedModule (DIScope *Context, DIModule *M, DIFile *File, unsigned Line, DINodeArray Elements=nullptr) |
Create a descriptor for an imported module. | |
DIImportedEntity * | createImportedDeclaration (DIScope *Context, DINode *Decl, DIFile *File, unsigned Line, StringRef Name="", DINodeArray Elements=nullptr) |
Create a descriptor for an imported function. | |
DbgInstPtr | insertDeclare (llvm::Value *Storage, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, BasicBlock *InsertAtEnd) |
Insert a new llvm.dbg.declare intrinsic call. | |
DbgInstPtr | insertDbgAssign (Instruction *LinkedInstr, Value *Val, DILocalVariable *SrcVar, DIExpression *ValExpr, Value *Addr, DIExpression *AddrExpr, const DILocation *DL) |
Insert a new llvm.dbg.assign intrinsic call. | |
DbgInstPtr | insertDeclare (llvm::Value *Storage, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, Instruction *InsertBefore) |
Insert a new llvm.dbg.declare intrinsic call. | |
DbgInstPtr | insertLabel (DILabel *LabelInfo, const DILocation *DL, Instruction *InsertBefore) |
Insert a new llvm.dbg.label intrinsic call. | |
DbgInstPtr | insertLabel (DILabel *LabelInfo, const DILocation *DL, BasicBlock *InsertAtEnd) |
Insert a new llvm.dbg.label intrinsic call. | |
DbgInstPtr | insertDbgValueIntrinsic (llvm::Value *Val, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, BasicBlock *InsertAtEnd) |
Insert a new llvm.dbg.value intrinsic call. | |
DbgInstPtr | insertDbgValueIntrinsic (llvm::Value *Val, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, Instruction *InsertBefore) |
Insert a new llvm.dbg.value intrinsic call. | |
void | replaceVTableHolder (DICompositeType *&T, DIType *VTableHolder) |
Replace the vtable holder in the given type. | |
void | replaceArrays (DICompositeType *&T, DINodeArray Elements, DINodeArray TParams=DINodeArray()) |
Replace arrays on a composite type. | |
template<class NodeTy > | |
NodeTy * | replaceTemporary (TempMDNode &&N, NodeTy *Replacement) |
Replace a temporary node. | |
Static Public Member Functions | |
static DISubprogram * | createArtificialSubprogram (DISubprogram *SP) |
Create a distinct clone of SP with FlagArtificial set. | |
static DIType * | createArtificialType (DIType *Ty) |
Create a uniqued clone of Ty with FlagArtificial set. | |
static DIType * | createObjectPointerType (DIType *Ty) |
Create a uniqued clone of Ty with FlagObjectPointer and FlagArtificial set. | |
Definition at line 45 of file DIBuilder.h.
|
explicit |
Construct a builder for a module.
If AllowUnresolved
, collect unresolved nodes attached to the module in order to resolve cycles during finalize().
If CU
is given a value other than nullptr, then set CUNode
to CU.
Definition at line 27 of file DIBuilder.cpp.
References llvm::DICompileUnit::getEnumTypes(), llvm::DICompileUnit::getGlobalVariables(), llvm::DICompileUnit::getImportedEntities(), llvm::DICompileUnit::getMacros(), and llvm::DICompileUnit::getRetainedTypes().
DICompositeType * DIBuilder::createArrayType | ( | uint64_t | Size, |
uint32_t | AlignInBits, | ||
DIType * | Ty, | ||
DINodeArray | Subscripts, | ||
PointerUnion< DIExpression *, DIVariable * > | DataLocation = nullptr , |
||
PointerUnion< DIExpression *, DIVariable * > | Associated = nullptr , |
||
PointerUnion< DIExpression *, DIVariable * > | Allocated = nullptr , |
||
PointerUnion< DIExpression *, DIVariable * > | Rank = nullptr |
||
) |
Create debugging information entry for an array.
Size | Array size. |
AlignInBits | Alignment. |
Ty | Element type. |
Subscripts | Subscripts. |
DataLocation | The location of the raw data of a descriptor-based Fortran array, either a DIExpression* or a DIVariable*. |
Associated | The associated attribute of a descriptor-based Fortran array, either a DIExpression* or a DIVariable*. |
Allocated | The allocated attribute of a descriptor-based Fortran array, either a DIExpression* or a DIVariable*. |
Rank | The rank attribute of a descriptor-based Fortran array, either a DIExpression* or a DIVariable*. |
Definition at line 597 of file DIBuilder.cpp.
References DL, llvm::MDNode::get(), and Size.
Referenced by solveDIType().
|
static |
Create a distinct clone of SP
with FlagArtificial set.
Definition at line 629 of file DIBuilder.cpp.
References llvm::MDNode::replaceWithDistinct().
Create a uniqued clone of Ty
with FlagArtificial set.
Definition at line 640 of file DIBuilder.cpp.
References createTypeWithFlags(), and llvm::DIType::isArtificial().
DILocalVariable * DIBuilder::createAutoVariable | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIType * | Ty, | ||
bool | AlwaysPreserve = false , |
||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
uint32_t | AlignInBits = 0 |
||
) |
Create a new descriptor for an auto variable.
This is a local variable that is not a subprogram parameter.
Scope
must be a DILocalScope, and thus its scope chain eventually leads to a DISubprogram.
If AlwaysPreserve
, this variable will be referenced from its containing subprogram, and will survive some optimizations.
Definition at line 809 of file DIBuilder.cpp.
References assert(), createLocalVariable(), and Name.
Referenced by buildFrameDebugInfo(), and fixupDebugInfoPostExtraction().
DIBasicType * DIBuilder::createBasicType | ( | StringRef | Name, |
uint64_t | SizeInBits, | ||
unsigned | Encoding, | ||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
uint32_t | NumExtraInhabitants = 0 |
||
) |
Create debugging information entry for a basic type.
Name | Type name. |
SizeInBits | Size of the type. |
Encoding | DWARF encoding code, e.g., dwarf::DW_ATE_float. |
Flags | Optional DWARF attributes, e.g., DW_AT_endianity. |
NumExtraInhabitants | The number of extra inhabitants of the type. An extra inhabitant is a bit pattern that does not represent a valid value for instances of a given type. This is used by the Swift language. |
Definition at line 266 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
Referenced by buildFrameDebugInfo(), and solveDIType().
DIDerivedType * DIBuilder::createBitFieldMemberType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
uint64_t | SizeInBits, | ||
uint64_t | OffsetInBits, | ||
uint64_t | StorageOffsetInBits, | ||
DINode::DIFlags | Flags, | ||
DIType * | Ty, | ||
DINodeArray | Annotations = nullptr |
||
) |
Create debugging information entry for a bit field member.
Scope | Member scope. |
Name | Member name. |
File | File where this member is defined. |
LineNo | Line number. |
SizeInBits | Member size. |
OffsetInBits | Member offset. |
StorageOffsetInBits | Member storage offset. |
Flags | Flags to encode member attribute. |
Ty | Parent type. |
Annotations | Member annotations. |
Definition at line 416 of file DIBuilder.cpp.
References llvm::ConstantAsMetadata::get(), llvm::IntegerType::get(), llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DICompositeType * DIBuilder::createClassType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNumber, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
uint64_t | OffsetInBits, | ||
DINode::DIFlags | Flags, | ||
DIType * | DerivedFrom, | ||
DINodeArray | Elements, | ||
unsigned | RunTimeLang = 0 , |
||
DIType * | VTableHolder = nullptr , |
||
MDNode * | TemplateParms = nullptr , |
||
StringRef | UniqueIdentifier = "" |
||
) |
Create debugging information entry for a class.
Scope | Scope in which this class is defined. |
Name | class name. |
File | File where this member is defined. |
LineNumber | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
OffsetInBits | Member offset. |
Flags | Flags to encode member attribute, e.g. private |
Elements | class members. |
RunTimeLang | Optional parameter, Objective-C runtime version. |
VTableHolder | Debug info of the base class that contains vtable for this type. This is used in DW_AT_containing_type. See DWARF documentation for more info. |
TemplateParms | Template type parameters. |
UniqueIdentifier | A unique identifier for the class. |
Definition at line 502 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DICommonBlock * DIBuilder::createCommonBlock | ( | DIScope * | Scope, |
DIGlobalVariable * | decl, | ||
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo | ||
) |
Create common block entry for a Fortran common block.
Scope | Scope of this common block. |
decl | Global variable declaration. |
Name | The name of this common block. |
File | The file this common block is defined. |
LineNo | Line number. |
Definition at line 916 of file DIBuilder.cpp.
References llvm::MDNode::get(), and Name.
DICompileUnit * DIBuilder::createCompileUnit | ( | unsigned | Lang, |
DIFile * | File, | ||
StringRef | Producer, | ||
bool | isOptimized, | ||
StringRef | Flags, | ||
unsigned | RV, | ||
StringRef | SplitName = StringRef() , |
||
DICompileUnit::DebugEmissionKind | Kind = DICompileUnit::DebugEmissionKind::FullDebug , |
||
uint64_t | DWOId = 0 , |
||
bool | SplitDebugInlining = true , |
||
bool | DebugInfoForProfiling = false , |
||
DICompileUnit::DebugNameTableKind | NameTableKind = DICompileUnit::DebugNameTableKind::Default , |
||
bool | RangesBaseAddress = false , |
||
StringRef | SysRoot = {} , |
||
StringRef | SDK = {} |
||
) |
A CompileUnit provides an anchor for all debugging information generated during this instance of compilation.
Lang | Source programming language, eg. dwarf::DW_LANG_C99 |
File | File info. |
Producer | Identify the producer of debugging information and code. Usually this is a compiler version string. |
isOptimized | A boolean flag which indicates whether optimization is enabled or not. |
Flags | This string lists command line options. This string is directly embedded in debug info output which may be used by a tool analyzing generated debugging information. |
RV | This indicates runtime version for languages like Objective-C. |
SplitName | The name of the file that we'll split debug info out into. |
Kind | The kind of debug information to generate. |
DWOId | The DWOId if this is a split skeleton compile unit. |
SplitDebugInlining | Whether to emit inline debug info. |
DebugInfoForProfiling | Whether to emit extra debug info for profile collection. |
NameTableKind | Whether to emit .debug_gnu_pubnames, .debug_pubnames, or no pubnames at all. |
SysRoot | The clang system root (value of -isysroot). |
SDK | The SDK name. On Darwin, this is the last component of the sysroot. |
Definition at line 134 of file DIBuilder.cpp.
References llvm::NamedMDNode::addOperand(), assert(), llvm::dwarf::DW_LANG_lo_user, llvm::MDNode::getDistinct(), and llvm::Module::getOrInsertNamedMetadata().
|
inline |
Create an expression for a variable that does not have an address, but does have a constant value.
Definition at line 789 of file DIBuilder.h.
References llvm::MDNode::get().
Referenced by llvm::getExpressionForConstant().
DICompositeType * DIBuilder::createEnumerationType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNumber, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
DINodeArray | Elements, | ||
DIType * | UnderlyingType, | ||
unsigned | RunTimeLang = 0 , |
||
StringRef | UniqueIdentifier = "" , |
||
bool | IsScoped = false |
||
) |
Create debugging information entry for an enumeration.
Scope | Scope in which this enumeration is defined. |
Name | Union name. |
File | File where this member is defined. |
LineNumber | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
Elements | Enumeration elements. |
UnderlyingType | Underlying type of a C++11/ObjC fixed enum. |
RunTimeLang | Optional parameter, Objective-C runtime version. |
UniqueIdentifier | A unique identifier for the enum. |
IsScoped | Boolean flag indicate if this is C++11/ObjC 'enum class'. |
Definition at line 569 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DIEnumerator * DIBuilder::createEnumerator | ( | StringRef | Name, |
const APSInt & | Value | ||
) |
Create a single enumerator value.
Definition at line 252 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
DIEnumerator * DIBuilder::createEnumerator | ( | StringRef | Name, |
uint64_t | Val, | ||
bool | IsUnsigned = false |
||
) |
Definition at line 245 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
DIExpression * DIBuilder::createExpression | ( | ArrayRef< uint64_t > | Addr = {} | ) |
Create a new descriptor for the specified variable which has a complex address expression for its address.
Addr | An array of complex address operations. |
Definition at line 847 of file DIBuilder.cpp.
References Addr, and llvm::MDNode::get().
Referenced by buildFrameDebugInfo(), and createGlobalVariableExpression().
DIFile * DIBuilder::createFile | ( | StringRef | Filename, |
StringRef | Directory, | ||
std::optional< DIFile::ChecksumInfo< StringRef > > | Checksum = std::nullopt , |
||
std::optional< StringRef > | Source = std::nullopt |
||
) |
Create a file descriptor to hold debugging information for a file.
Filename | File name. |
Directory | Directory. |
Checksum | Optional checksum kind (e.g. CSK_MD5, CSK_SHA1, etc.) and value. |
Source | Optional source text. |
Definition at line 214 of file DIBuilder.cpp.
References llvm::MDNode::get().
DICompositeType * DIBuilder::createForwardDecl | ( | unsigned | Tag, |
StringRef | Name, | ||
DIScope * | Scope, | ||
DIFile * | F, | ||
unsigned | Line, | ||
unsigned | RuntimeLang = 0 , |
||
uint64_t | SizeInBits = 0 , |
||
uint32_t | AlignInBits = 0 , |
||
StringRef | UniqueIdentifier = "" |
||
) |
Create a permanent forward-declared type.
Definition at line 666 of file DIBuilder.cpp.
References F, llvm::MDNode::get(), getNonCompileUnitScope(), Name, and RetTy.
DIDerivedType * DIBuilder::createFriend | ( | DIType * | Ty, |
DIType * | FriendTy | ||
) |
Create debugging information entry for a 'friend'.
Definition at line 370 of file DIBuilder.cpp.
References assert(), and llvm::MDNode::get().
DISubprogram * DIBuilder::createFunction | ( | DIScope * | Scope, |
StringRef | Name, | ||
StringRef | LinkageName, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DISubroutineType * | Ty, | ||
unsigned | ScopeLine, | ||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
DISubprogram::DISPFlags | SPFlags = DISubprogram::SPFlagZero , |
||
DITemplateParameterArray | TParams = nullptr , |
||
DISubprogram * | Decl = nullptr , |
||
DITypeArray | ThrownTypes = nullptr , |
||
DINodeArray | Annotations = nullptr , |
||
StringRef | TargetFuncName = "" |
||
) |
Create a new descriptor for the specified subprogram.
See comments in DISubprogram* for descriptions of these fields.
Scope | Function scope. |
Name | Function name. |
LinkageName | Mangled function name. |
File | File where this variable is defined. |
LineNo | Line number. |
Ty | Function type. |
ScopeLine | Set to the beginning of the scope this starts |
Flags | e.g. is this function prototyped or not. These flags are used to emit dwarf attributes. |
SPFlags | Additional flags specific to subprograms. |
TParams | Function template parameters. |
ThrownTypes | Exception types this function may throw. |
Annotations | Attribute Annotations. |
TargetFuncName | The name of the target function if this is a trampoline. |
Definition at line 858 of file DIBuilder.cpp.
References getNonCompileUnitScope(), getSubprogram(), llvm::LinkageName, and Name.
Referenced by fixupDebugInfoPostExtraction().
DIGlobalVariableExpression * DIBuilder::createGlobalVariableExpression | ( | DIScope * | Context, |
StringRef | Name, | ||
StringRef | LinkageName, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIType * | Ty, | ||
bool | IsLocalToUnit, | ||
bool | isDefined = true , |
||
DIExpression * | Expr = nullptr , |
||
MDNode * | Decl = nullptr , |
||
MDTuple * | TemplateParams = nullptr , |
||
uint32_t | AlignInBits = 0 , |
||
DINodeArray | Annotations = nullptr |
||
) |
Create a new descriptor for the specified variable.
Context | Variable scope. |
Name | Name of the variable. |
LinkageName | Mangled name of the variable. |
File | File where this variable is defined. |
LineNo | Line number. |
Ty | Variable Type. |
IsLocalToUnit | Boolean flag indicate whether this variable is externally visible or not. |
Expr | The location of the global relative to the attached GlobalVariable. |
Decl | Reference to the corresponding declaration. |
AlignInBits | Variable alignment(or 0 if no alignment attr was specified) |
Definition at line 756 of file DIBuilder.cpp.
References checkGlobalVariableScope(), createExpression(), F, llvm::MDNode::get(), llvm::MDNode::getDistinct(), llvm::LinkageName, N, and Name.
DIImportedEntity * DIBuilder::createImportedDeclaration | ( | DIScope * | Context, |
DINode * | Decl, | ||
DIFile * | File, | ||
unsigned | Line, | ||
StringRef | Name = "" , |
||
DINodeArray | Elements = nullptr |
||
) |
Create a descriptor for an imported function.
Context | The scope this module is imported into. |
Decl | The declaration (or definition) of a function, type, or variable. |
File | File where the declaration is located. |
Line | Line number of the declaration. |
Elements | Renamed elements. |
Definition at line 204 of file DIBuilder.cpp.
References Name.
DIImportedEntity * DIBuilder::createImportedModule | ( | DIScope * | Context, |
DIImportedEntity * | NS, | ||
DIFile * | File, | ||
unsigned | Line, | ||
DINodeArray | Elements = nullptr |
||
) |
Create a descriptor for an imported module.
Context | The scope this module is imported into. |
NS | An aliased namespace. |
File | File where the declaration is located. |
Line | Line number of the declaration. |
Elements | Renamed elements. |
Definition at line 186 of file DIBuilder.cpp.
DIImportedEntity * DIBuilder::createImportedModule | ( | DIScope * | Context, |
DIModule * | M, | ||
DIFile * | File, | ||
unsigned | Line, | ||
DINodeArray | Elements = nullptr |
||
) |
Create a descriptor for an imported module.
Context | The scope this module is imported into. |
M | The module being imported here |
File | File where the declaration is located. |
Line | Line number of the declaration. |
Elements | Renamed elements. |
Definition at line 195 of file DIBuilder.cpp.
DIImportedEntity * DIBuilder::createImportedModule | ( | DIScope * | Context, |
DINamespace * | NS, | ||
DIFile * | File, | ||
unsigned | Line, | ||
DINodeArray | Elements = nullptr |
||
) |
Create a descriptor for an imported module.
Context | The scope this module is imported into |
NS | The namespace being imported here. |
File | File where the declaration is located. |
Line | Line number of the declaration. |
Elements | Renamed elements. |
Definition at line 177 of file DIBuilder.cpp.
DIDerivedType * DIBuilder::createInheritance | ( | DIType * | Ty, |
DIType * | BaseTy, | ||
uint64_t | BaseOffset, | ||
uint32_t | VBPtrOffset, | ||
DINode::DIFlags | Flags | ||
) |
Create debugging information entry to establish inheritance relationship between two types.
Ty | Original type. |
BaseTy | Base type. Ty is inherits from base. |
BaseOffset | Base offset. |
VBPtrOffset | Virtual base pointer offset. |
Flags | Flags to describe inheritance attribute, e.g. private |
Definition at line 378 of file DIBuilder.cpp.
References assert(), llvm::ConstantAsMetadata::get(), llvm::IntegerType::get(), and llvm::MDNode::get().
DILabel * DIBuilder::createLabel | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
bool | AlwaysPreserve = false |
||
) |
Create a new descriptor for an label.
Scope
must be a DILocalScope, and thus its scope chain eventually leads to a DISubprogram.
The optimizer may remove labels. If there is an interest to preserve label info in such situation then append it to the list of retained nodes of the DISubprogram.
Definition at line 833 of file DIBuilder.cpp.
References llvm::MDNode::get(), and Name.
DILexicalBlock * DIBuilder::createLexicalBlock | ( | DIScope * | Scope, |
DIFile * | File, | ||
unsigned | Line, | ||
unsigned | Col | ||
) |
This creates a descriptor for a lexical block with the specified parent context.
Scope | Parent lexical scope. |
File | Source file. |
Line | Line number. |
Col | Column number. |
Definition at line 950 of file DIBuilder.cpp.
References llvm::MDNode::getDistinct(), and getNonCompileUnitScope().
DILexicalBlockFile * DIBuilder::createLexicalBlockFile | ( | DIScope * | Scope, |
DIFile * | File, | ||
unsigned | Discriminator = 0 |
||
) |
This creates a descriptor for a lexical block with a new file attached.
This merely extends the existing lexical block as it crosses a file.
Scope | Lexical block. |
File | Source file. |
Discriminator | DWARF path discriminator value. |
Definition at line 944 of file DIBuilder.cpp.
References llvm::MDNode::get().
DIMacro * DIBuilder::createMacro | ( | DIMacroFile * | Parent, |
unsigned | Line, | ||
unsigned | MacroType, | ||
StringRef | Name, | ||
StringRef | Value = StringRef() |
||
) |
Create debugging information entry for a macro.
Parent | Macro parent (could be nullptr). |
Line | Source line number where the macro is defined. |
MacroType | DW_MACINFO_define or DW_MACINFO_undef. |
Name | Macro name. |
Value | Macro value. |
Definition at line 220 of file DIBuilder.cpp.
References assert(), llvm::dwarf::DW_MACINFO_define, llvm::dwarf::DW_MACINFO_undef, llvm::MDNode::get(), and Name.
DIDerivedType * DIBuilder::createMemberPointerType | ( | DIType * | PointeeTy, |
DIType * | Class, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits = 0 , |
||
DINode::DIFlags | Flags = DINode::FlagZero |
||
) |
Create debugging information entry for a pointer to member.
PointeeTy | Type pointed to by this pointer. |
SizeInBits | Size. |
AlignInBits | Alignment. (optional) |
Class | Type for which this pointer points to members of. |
Definition at line 327 of file DIBuilder.cpp.
References llvm::sampleprof::Base, and llvm::MDNode::get().
DIDerivedType * DIBuilder::createMemberType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
uint64_t | OffsetInBits, | ||
DINode::DIFlags | Flags, | ||
DIType * | Ty, | ||
DINodeArray | Annotations = nullptr |
||
) |
Create debugging information entry for a member.
Scope | Member scope. |
Name | Member name. |
File | File where this member is defined. |
LineNo | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
OffsetInBits | Member offset. |
Flags | Flags to encode member attribute, e.g. private |
Ty | Parent type. |
Annotations | Member annotations. |
Definition at line 390 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
Referenced by buildFrameDebugInfo(), and solveDIType().
DISubprogram * DIBuilder::createMethod | ( | DIScope * | Scope, |
StringRef | Name, | ||
StringRef | LinkageName, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DISubroutineType * | Ty, | ||
unsigned | VTableIndex = 0 , |
||
int | ThisAdjustment = 0 , |
||
DIType * | VTableHolder = nullptr , |
||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
DISubprogram::DISPFlags | SPFlags = DISubprogram::SPFlagZero , |
||
DITemplateParameterArray | TParams = nullptr , |
||
DITypeArray | ThrownTypes = nullptr |
||
) |
Create a new descriptor for the specified C++ method.
See comments in DISubprogram* for descriptions of these fields.
Scope | Function scope. |
Name | Function name. |
LinkageName | Mangled function name. |
File | File where this variable is defined. |
LineNo | Line number. |
Ty | Function type. |
VTableIndex | Index no of this method in virtual table, or -1u if unrepresentable. |
ThisAdjustment | MS ABI-specific adjustment of 'this' that occurs in the prologue. |
VTableHolder | Type that holds vtable. |
Flags | e.g. is this function prototyped or not. This flags are used to emit dwarf attributes. |
SPFlags | Additional flags specific to subprograms. |
TParams | Function template parameters. |
ThrownTypes | Exception types this function may throw. |
Definition at line 893 of file DIBuilder.cpp.
References assert(), F, getNonCompileUnitScope(), getSubprogram(), llvm::LinkageName, and Name.
DIModule * DIBuilder::createModule | ( | DIScope * | Scope, |
StringRef | Name, | ||
StringRef | ConfigurationMacros, | ||
StringRef | IncludePath, | ||
StringRef | APINotesFile = {} , |
||
DIFile * | File = nullptr , |
||
unsigned | LineNo = 0 , |
||
bool | IsDecl = false |
||
) |
This creates new descriptor for a module with the specified parent scope.
Scope | Parent scope |
Name | Name of this module |
ConfigurationMacros | A space-separated shell-quoted list of -D macro definitions as they would appear on a command line. |
IncludePath | The path to the module map file. |
APINotesFile | The path to an API notes file for this module. |
File | Source file of the module. Used for Fortran modules. |
LineNo | Source line number of the module. Used for Fortran modules. |
IsDecl | This is a module declaration; default to false; when set to true, only Scope and Name are required as this entry is just a hint for the debugger to find the corresponding definition in the global scope. |
Definition at line 935 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DINamespace * DIBuilder::createNameSpace | ( | DIScope * | Scope, |
StringRef | Name, | ||
bool | ExportSymbols | ||
) |
This creates new descriptor for a namespace with the specified parent scope.
Scope | Namespace scope |
Name | Name of this namespace |
ExportSymbols | True for C++ inline namespaces. |
Definition at line 923 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DIBasicType * DIBuilder::createNullPtrType | ( | ) |
Create C++11 nullptr type.
Definition at line 262 of file DIBuilder.cpp.
References createUnspecifiedType().
DIDerivedType * DIBuilder::createObjCIVar | ( | StringRef | Name, |
DIFile * | File, | ||
unsigned | LineNo, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
uint64_t | OffsetInBits, | ||
DINode::DIFlags | Flags, | ||
DIType * | Ty, | ||
MDNode * | PropertyNode | ||
) |
Create debugging information entry for Objective-C instance variable.
Name | Member name. |
File | File where this member is defined. |
LineNo | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
OffsetInBits | Member offset. |
Flags | Flags to encode member attribute, e.g. private |
Ty | Parent type. |
PropertyNode | Property associated with this ivar. |
Definition at line 443 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DIObjCProperty * DIBuilder::createObjCProperty | ( | StringRef | Name, |
DIFile * | File, | ||
unsigned | LineNumber, | ||
StringRef | GetterName, | ||
StringRef | SetterName, | ||
unsigned | PropertyAttributes, | ||
DIType * | Ty | ||
) |
Create debugging information entry for Objective-C property.
Name | Property name. |
File | File where this property is defined. |
LineNumber | Line number. |
GetterName | Name of the Objective C property getter selector. |
SetterName | Name of the Objective C property setter selector. |
PropertyAttributes | Objective C property attributes. |
Ty | Type. |
Definition at line 454 of file DIBuilder.cpp.
References llvm::MDNode::get(), and Name.
Create a uniqued clone of Ty
with FlagObjectPointer and FlagArtificial set.
Definition at line 647 of file DIBuilder.cpp.
References createTypeWithFlags(), and llvm::DIType::isObjectPointer().
DILocalVariable * DIBuilder::createParameterVariable | ( | DIScope * | Scope, |
StringRef | Name, | ||
unsigned | ArgNo, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIType * | Ty, | ||
bool | AlwaysPreserve = false , |
||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
DINodeArray | Annotations = nullptr |
||
) |
Create a new descriptor for a parameter variable.
Scope
must be a DILocalScope, and thus its scope chain eventually leads to a DISubprogram.
ArgNo
is the index (starting from 1
) of this variable in the subprogram parameters. ArgNo
should not conflict with other parameters of the same subprogram.
If AlwaysPreserve
, this variable will be referenced from its containing subprogram, and will survive some optimizations.
Definition at line 821 of file DIBuilder.cpp.
References assert(), createLocalVariable(), and Name.
DIDerivedType * DIBuilder::createPointerType | ( | DIType * | PointeeTy, |
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits = 0 , |
||
std::optional< unsigned > | DWARFAddressSpace = std::nullopt , |
||
StringRef | Name = "" , |
||
DINodeArray | Annotations = nullptr |
||
) |
Create debugging information entry for a pointer.
PointeeTy | Type pointed by this pointer. |
SizeInBits | Size. |
AlignInBits | Alignment. (optional) |
DWARFAddressSpace | DWARF address space. (optional) |
Name | Pointer type name. (optional) |
Annotations | Member annotations. |
Definition at line 316 of file DIBuilder.cpp.
References llvm::MDNode::get(), and Name.
Referenced by buildFrameDebugInfo(), and solveDIType().
DIDerivedType * DIBuilder::createPtrAuthQualifiedType | ( | DIType * | FromTy, |
unsigned | Key, | ||
bool | IsAddressDiscriminated, | ||
unsigned | ExtraDiscriminator, | ||
bool | IsaPointer, | ||
bool | authenticatesNullValues | ||
) |
Create a __ptrauth qualifier.
Definition at line 302 of file DIBuilder.cpp.
References llvm::MDNode::get().
DIDerivedType * DIBuilder::createQualifiedType | ( | unsigned | Tag, |
DIType * | FromTy | ||
) |
Create debugging information entry for a qualified type, e.g.
'const int'.
Tag | Tag identifing type, e.g. dwarf::TAG_volatile_type |
FromTy | Base Type. |
Definition at line 297 of file DIBuilder.cpp.
References llvm::MDNode::get().
DIDerivedType * DIBuilder::createReferenceType | ( | unsigned | Tag, |
DIType * | RTy, | ||
uint64_t | SizeInBits = 0 , |
||
uint32_t | AlignInBits = 0 , |
||
std::optional< unsigned > | DWARFAddressSpace = std::nullopt |
||
) |
Create debugging information entry for a c++ style reference or rvalue reference type.
Definition at line 339 of file DIBuilder.cpp.
References assert(), and llvm::MDNode::get().
DICompositeType * DIBuilder::createReplaceableCompositeType | ( | unsigned | Tag, |
StringRef | Name, | ||
DIScope * | Scope, | ||
DIFile * | F, | ||
unsigned | Line, | ||
unsigned | RuntimeLang = 0 , |
||
uint64_t | SizeInBits = 0 , |
||
uint32_t | AlignInBits = 0 , |
||
DINode::DIFlags | Flags = DINode::FlagFwdDecl , |
||
StringRef | UniqueIdentifier = "" , |
||
DINodeArray | Annotations = nullptr |
||
) |
Create a temporary forward-declared type.
Definition at line 680 of file DIBuilder.cpp.
References F, getNonCompileUnitScope(), llvm::MDNode::getTemporary(), Name, and RetTy.
DIDerivedType * DIBuilder::createSetType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
DIType * | Ty | ||
) |
Create debugging information entry for a set.
Scope | Scope in which this set is defined. |
Name | Set name. |
File | File where this set is defined. |
LineNo | Line number. |
SizeInBits | Set size. |
AlignInBits | Set alignment. |
Ty | Base type of the set. |
Definition at line 584 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DIDerivedType * DIBuilder::createStaticMemberType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIType * | Ty, | ||
DINode::DIFlags | Flags, | ||
llvm::Constant * | Val, | ||
unsigned | Tag, | ||
uint32_t | AlignInBits = 0 |
||
) |
Create debugging information entry for a C++ static data member.
Scope | Member scope. |
Name | Member name. |
File | File where this member is declared. |
LineNo | Line number. |
Ty | Type of the static member. |
Flags | Flags to encode member attribute, e.g. private. |
Val | Const initializer of the member. |
Tag | DWARF tag of the static member. |
AlignInBits | Member alignment. |
Definition at line 431 of file DIBuilder.cpp.
References llvm::MDNode::get(), getConstantOrNull(), getNonCompileUnitScope(), and Name.
DIStringType * DIBuilder::createStringType | ( | StringRef | Name, |
DIExpression * | StringLengthExp, | ||
DIExpression * | StrLocationExp = nullptr |
||
) |
Create debugging information entry for Fortran assumed length string type.
Name | Type name. |
StringLengthExp | String length expressed in DIExpression form. |
StrLocationExp | Optional memory location of the string. |
Definition at line 289 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
DIStringType * DIBuilder::createStringType | ( | StringRef | Name, |
DIVariable * | StringLength, | ||
DIExpression * | StrLocationExp = nullptr |
||
) |
Create debugging information entry for Fortran assumed length string type.
Name | Type name. |
StringLength | String length expressed as DIVariable *. |
StrLocationExp | Optional memory location of the string. |
Definition at line 281 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
DIStringType * DIBuilder::createStringType | ( | StringRef | Name, |
uint64_t | SizeInBits | ||
) |
Create debugging information entry for a string type.
Name | Type name. |
SizeInBits | Size of the type. |
Definition at line 275 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
DICompositeType * DIBuilder::createStructType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNumber, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
DINode::DIFlags | Flags, | ||
DIType * | DerivedFrom, | ||
DINodeArray | Elements, | ||
unsigned | RunTimeLang = 0 , |
||
DIType * | VTableHolder = nullptr , |
||
StringRef | UniqueIdentifier = "" , |
||
DIType * | Specification = nullptr , |
||
uint32_t | NumExtraInhabitants = 0 |
||
) |
Create debugging information entry for a struct.
Scope | Scope in which this struct is defined. |
Name | Struct name. |
File | File where this member is defined. |
LineNumber | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
Flags | Flags to encode member attribute, e.g. private |
Elements | Struct elements. |
RunTimeLang | Optional parameter, Objective-C runtime version. |
UniqueIdentifier | A unique identifier for the struct. |
Specification | The type that this type completes. This is used by Swift to represent generic types. |
NumExtraInhabitants | The number of extra inhabitants of the type. An extra inhabitant is a bit pattern that does not represent a valid value for instances of a given type. This is used by the Swift language. |
Definition at line 520 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
Referenced by buildFrameDebugInfo(), and solveDIType().
DISubroutineType * DIBuilder::createSubroutineType | ( | DITypeRefArray | ParameterTypes, |
DINode::DIFlags | Flags = DINode::FlagZero , |
||
unsigned | CC = 0 |
||
) |
Create subroutine type.
ParameterTypes | An array of subroutine parameter types. This includes return type at 0th index. |
Flags | E.g.: LValueReference. These flags are used to emit dwarf attributes. |
CC | Calling convention, e.g. dwarf::DW_CC_normal |
Definition at line 562 of file DIBuilder.cpp.
References CC, and llvm::MDNode::get().
Referenced by fixupDebugInfoPostExtraction().
DISubprogram * DIBuilder::createTempFunctionFwdDecl | ( | DIScope * | Scope, |
StringRef | Name, | ||
StringRef | LinkageName, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DISubroutineType * | Ty, | ||
unsigned | ScopeLine, | ||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
DISubprogram::DISPFlags | SPFlags = DISubprogram::SPFlagZero , |
||
DITemplateParameterArray | TParams = nullptr , |
||
DISubprogram * | Decl = nullptr , |
||
DITypeArray | ThrownTypes = nullptr |
||
) |
Identical to createFunction, except that the resulting DbgNode is meant to be RAUWed.
Definition at line 878 of file DIBuilder.cpp.
References getNonCompileUnitScope(), llvm::MDNode::getTemporary(), llvm::LinkageName, and Name.
DIGlobalVariable * DIBuilder::createTempGlobalVariableFwdDecl | ( | DIScope * | Context, |
StringRef | Name, | ||
StringRef | LinkageName, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIType * | Ty, | ||
bool | IsLocalToUnit, | ||
MDNode * | Decl = nullptr , |
||
MDTuple * | TemplateParams = nullptr , |
||
uint32_t | AlignInBits = 0 |
||
) |
Identical to createGlobalVariable except that the resulting DbgNode is temporary and meant to be RAUWed.
Definition at line 775 of file DIBuilder.cpp.
References checkGlobalVariableScope(), F, llvm::MDNode::getTemporary(), llvm::LinkageName, and Name.
DIDerivedType * DIBuilder::createTemplateAlias | ( | DIType * | Ty, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIScope * | Context, | ||
DINodeArray | TParams, | ||
uint32_t | AlignInBits = 0 , |
||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
DINodeArray | Annotations = nullptr |
||
) |
Create debugging information entry for a template alias.
Ty | Original type. |
Name | Alias name. |
File | File where this type is defined. |
LineNo | Line number. |
Context | The surrounding context for the alias. |
TParams | The template arguments. |
AlignInBits | Alignment. (optional) |
Flags | Flags to describe inheritance attribute (optional), e.g. private. |
Annotations | Annotations. (optional) |
Definition at line 360 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DITemplateValueParameter * DIBuilder::createTemplateParameterPack | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIType * | Ty, | ||
DINodeArray | Val | ||
) |
Create debugging information for a template parameter pack.
Scope | Scope in which this type is defined. |
Name | Value parameter name. |
Ty | Parameter type. |
Val | An array of types in the pack. |
Definition at line 495 of file DIBuilder.cpp.
References createTemplateValueParameterHelper(), llvm::MDNode::get(), and Name.
DITemplateValueParameter * DIBuilder::createTemplateTemplateParameter | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIType * | Ty, | ||
StringRef | Val, | ||
bool | IsDefault = false |
||
) |
Create debugging information for a template template parameter.
Scope | Scope in which this type is defined. |
Name | Value parameter name. |
Ty | Parameter type. |
Val | The fully qualified name of the template. |
IsDefault | Parameter is default or not. |
Definition at line 486 of file DIBuilder.cpp.
References createTemplateValueParameterHelper(), llvm::MDString::get(), and Name.
DITemplateTypeParameter * DIBuilder::createTemplateTypeParameter | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIType * | Ty, | ||
bool | IsDefault | ||
) |
Create debugging information for template type parameter.
Scope | Scope in which this type is defined. |
Name | Type parameter name. |
Ty | Parameter type. |
IsDefault | Parameter is default or not |
Definition at line 462 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
DITemplateValueParameter * DIBuilder::createTemplateValueParameter | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIType * | Ty, | ||
bool | IsDefault, | ||
Constant * | Val | ||
) |
Create debugging information for template value parameter.
Scope | Scope in which this type is defined. |
Name | Value parameter name. |
Ty | Parameter type. |
IsDefault | Parameter is default or not |
Val | Constant parameter value. |
Definition at line 477 of file DIBuilder.cpp.
References createTemplateValueParameterHelper(), getConstantOrNull(), and Name.
DIMacroFile * DIBuilder::createTempMacroFile | ( | DIMacroFile * | Parent, |
unsigned | Line, | ||
DIFile * | File | ||
) |
Create debugging information temporary entry for a macro file.
List of macro node direct children will be calculated by DIBuilder, using the Parent
relationship.
Parent | Macro file parent (could be nullptr). |
Line | Source line number where the macro file is included. |
File | File descriptor containing the name of the macro file. |
Definition at line 232 of file DIBuilder.cpp.
References llvm::dwarf::DW_MACINFO_start_file, and llvm::MDNode::getTemporary().
DIDerivedType * DIBuilder::createTypedef | ( | DIType * | Ty, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
DIScope * | Context, | ||
uint32_t | AlignInBits = 0 , |
||
DINode::DIFlags | Flags = DINode::FlagZero , |
||
DINodeArray | Annotations = nullptr |
||
) |
Create debugging information entry for a typedef.
Ty | Original type. |
Name | Typedef name. |
File | File where this type is defined. |
LineNo | Line number. |
Context | The surrounding context for the typedef. |
AlignInBits | Alignment. (optional) |
Flags | Flags to describe inheritance attribute, e.g. private |
Annotations | Annotations. (optional) |
Definition at line 348 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DICompositeType * DIBuilder::createUnionType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNumber, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
DINode::DIFlags | Flags, | ||
DINodeArray | Elements, | ||
unsigned | RunTimeLang = 0 , |
||
StringRef | UniqueIdentifier = "" |
||
) |
Create debugging information entry for an union.
Scope | Scope in which this union is defined. |
Name | Union name. |
File | File where this member is defined. |
LineNumber | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
Flags | Flags to encode member attribute, e.g. private |
Elements | Union elements. |
RunTimeLang | Optional parameter, Objective-C runtime version. |
UniqueIdentifier | A unique identifier for the union. |
Definition at line 536 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DIBasicType * DIBuilder::createUnspecifiedParameter | ( | ) |
Create unspecified parameter type for a subroutine type.
Definition at line 663 of file DIBuilder.cpp.
DIBasicType * DIBuilder::createUnspecifiedType | ( | StringRef | Name | ) |
Create a DWARF unspecified type.
Definition at line 257 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and Name.
Referenced by createNullPtrType().
DIDerivedType * DIBuilder::createVariantMemberType | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNo, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
uint64_t | OffsetInBits, | ||
Constant * | Discriminant, | ||
DINode::DIFlags | Flags, | ||
DIType * | Ty | ||
) |
Create debugging information entry for a variant.
A variant normally should be a member of a variant part.
Scope | Member scope. |
Name | Member name. |
File | File where this member is defined. |
LineNo | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
OffsetInBits | Member offset. |
Flags | Flags to encode member attribute, e.g. private |
Discriminant | The discriminant for this branch; null for the default branch |
Ty | Parent type. |
Definition at line 406 of file DIBuilder.cpp.
References llvm::MDNode::get(), getConstantOrNull(), getNonCompileUnitScope(), and Name.
DICompositeType * DIBuilder::createVariantPart | ( | DIScope * | Scope, |
StringRef | Name, | ||
DIFile * | File, | ||
unsigned | LineNumber, | ||
uint64_t | SizeInBits, | ||
uint32_t | AlignInBits, | ||
DINode::DIFlags | Flags, | ||
DIDerivedType * | Discriminator, | ||
DINodeArray | Elements, | ||
StringRef | UniqueIdentifier = "" |
||
) |
Create debugging information entry for a variant part.
A variant part normally has a discriminator (though this is not required) and a number of variant children.
Scope | Scope in which this union is defined. |
Name | Union name. |
File | File where this member is defined. |
LineNumber | Line number. |
SizeInBits | Member size. |
AlignInBits | Member alignment. |
Flags | Flags to encode member attribute, e.g. private |
Discriminator | Discriminant member |
Elements | Variant elements. |
UniqueIdentifier | A unique identifier for the union. |
Definition at line 549 of file DIBuilder.cpp.
References llvm::MDNode::get(), getNonCompileUnitScope(), and Name.
DICompositeType * DIBuilder::createVectorType | ( | uint64_t | Size, |
uint32_t | AlignInBits, | ||
DIType * | Ty, | ||
DINodeArray | Subscripts | ||
) |
Create debugging information entry for a vector type.
Size | Array size. |
AlignInBits | Alignment. |
Ty | Element type. |
Subscripts | Subscripts. |
Definition at line 619 of file DIBuilder.cpp.
References llvm::MDNode::get(), and Size.
void DIBuilder::finalize | ( | ) |
Construct any deferred debug info descriptors.
Definition at line 63 of file DIBuilder.cpp.
References assert(), llvm::dwarf::DW_MACINFO_start_file, llvm::SmallVectorBase< Size_T >::empty(), finalizeSubprogram(), llvm::MDNode::get(), llvm::MDTuple::get(), getOrCreateMacroArray(), I, llvm::SmallPtrSetImpl< PtrType >::insert(), N, llvm::SmallVectorTemplateBase< T, bool >::push_back(), llvm::DICompileUnit::replaceEnumTypes(), llvm::DICompileUnit::replaceGlobalVariables(), llvm::DICompileUnit::replaceImportedEntities(), llvm::DICompileUnit::replaceMacros(), llvm::DICompileUnit::replaceRetainedTypes(), and replaceTemporary().
void DIBuilder::finalizeSubprogram | ( | DISubprogram * | SP | ) |
Finalize a specific subprogram - no new variables may be added to this subprogram afterwards.
Definition at line 55 of file DIBuilder.cpp.
References llvm::MDTuple::get().
Referenced by finalize(), and fixupDebugInfoPostExtraction().
Get a DINodeArray, create one if required.
Definition at line 696 of file DIBuilder.cpp.
References llvm::MDTuple::get().
Referenced by buildFrameDebugInfo(), and solveDIType().
DIGenericSubrange * DIBuilder::getOrCreateGenericSubrange | ( | DIGenericSubrange::BoundType | Count, |
DIGenericSubrange::BoundType | LowerBound, | ||
DIGenericSubrange::BoundType | UpperBound, | ||
DIGenericSubrange::BoundType | Stride | ||
) |
Definition at line 735 of file DIBuilder.cpp.
References llvm::MDNode::get().
Get a DIMacroNodeArray, create one if required.
Definition at line 701 of file DIBuilder.cpp.
References llvm::MDTuple::get().
Referenced by finalize().
DISubrange * DIBuilder::getOrCreateSubrange | ( | int64_t | Lo, |
int64_t | Count | ||
) |
Create a descriptor for a value range.
This implicitly uniques the values returned.
Definition at line 716 of file DIBuilder.cpp.
References llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), llvm::Type::getInt64Ty(), llvm::ConstantInt::getSigned(), and llvm::Lo.
Referenced by solveDIType().
DISubrange * DIBuilder::getOrCreateSubrange | ( | int64_t | Lo, |
Metadata * | CountNode | ||
) |
Definition at line 724 of file DIBuilder.cpp.
References llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), llvm::Type::getInt64Ty(), llvm::ConstantInt::getSigned(), and llvm::Lo.
DISubrange * DIBuilder::getOrCreateSubrange | ( | Metadata * | Count, |
Metadata * | LowerBound, | ||
Metadata * | UpperBound, | ||
Metadata * | Stride | ||
) |
Definition at line 730 of file DIBuilder.cpp.
References llvm::MDNode::get().
DITypeRefArray DIBuilder::getOrCreateTypeArray | ( | ArrayRef< Metadata * > | Elements | ) |
Get a DITypeRefArray, create one if required.
Definition at line 705 of file DIBuilder.cpp.
References llvm::MDNode::get(), and llvm::SmallVectorTemplateBase< T, bool >::push_back().
Referenced by fixupDebugInfoPostExtraction().
DbgInstPtr DIBuilder::insertDbgAssign | ( | Instruction * | LinkedInstr, |
Value * | Val, | ||
DILocalVariable * | SrcVar, | ||
DIExpression * | ValExpr, | ||
Value * | Addr, | ||
DIExpression * | AddrExpr, | ||
const DILocation * | DL | ||
) |
Insert a new llvm.dbg.assign intrinsic call.
LinkedInstr | Instruction with a DIAssignID to link with the new intrinsic. The intrinsic will be inserted after this instruction. |
Val | The value component of this dbg.assign. |
SrcVar | Variable's debug info descriptor. |
ValExpr | A complex location expression to modify Val . |
Addr | The address component (store destination). |
AddrExpr | A complex location expression to modify Addr . NOTE: ValExpr carries the FragInfo for the variable. |
DL | Debug info location, usually: (line: 0, column: 0, scope: var-decl-scope). See getDebugValueLoc. |
Definition at line 974 of file DIBuilder.cpp.
References Addr, assert(), B, llvm::DbgVariableRecord::createDVRAssign(), DL, llvm::BasicBlock::end(), llvm::MetadataAsValue::get(), llvm::ValueAsMetadata::get(), llvm::Value::getContext(), llvm::ilist_node_impl< OptionsT >::getIterator(), llvm::Instruction::getMetadata(), llvm::Instruction::getModule(), llvm::Intrinsic::getOrInsertDeclaration(), llvm::ilist_detail::node_parent_access< NodeTy, ParentTy >::getParent(), and llvm::Module::IsNewDbgInfoFormat.
Referenced by emitDbgAssign(), insertNewDbgInst(), and migrateDebugInfo().
DbgInstPtr DIBuilder::insertDbgValueIntrinsic | ( | llvm::Value * | Val, |
DILocalVariable * | VarInfo, | ||
DIExpression * | Expr, | ||
const DILocation * | DL, | ||
BasicBlock * | InsertAtEnd | ||
) |
Insert a new llvm.dbg.value intrinsic call.
Val | llvm::Value of the variable |
VarInfo | Variable's debug info descriptor. |
Expr | A complex location expression. |
DL | Debug info location. |
InsertAtEnd | Location for the new intrinsic. |
Definition at line 1041 of file DIBuilder.cpp.
References DL.
DbgInstPtr DIBuilder::insertDbgValueIntrinsic | ( | llvm::Value * | Val, |
DILocalVariable * | VarInfo, | ||
DIExpression * | Expr, | ||
const DILocation * | DL, | ||
Instruction * | InsertBefore | ||
) |
Insert a new llvm.dbg.value intrinsic call.
Val | llvm::Value of the variable |
VarInfo | Variable's debug info descriptor. |
Expr | A complex location expression. |
DL | Debug info location. |
InsertBefore | Location for the new intrinsic. |
Definition at line 1028 of file DIBuilder.cpp.
References DL, and llvm::ilist_detail::node_parent_access< NodeTy, ParentTy >::getParent().
DbgInstPtr DIBuilder::insertDeclare | ( | llvm::Value * | Storage, |
DILocalVariable * | VarInfo, | ||
DIExpression * | Expr, | ||
const DILocation * | DL, | ||
BasicBlock * | InsertAtEnd | ||
) |
Insert a new llvm.dbg.declare intrinsic call.
Storage | llvm::Value of the variable |
VarInfo | Variable's debug info descriptor. |
Expr | A complex location expression. |
DL | Debug info location. |
InsertAtEnd | Location for the new intrinsic. |
Definition at line 965 of file DIBuilder.cpp.
References DL, and llvm::BasicBlock::getTerminator().
DbgInstPtr DIBuilder::insertDeclare | ( | llvm::Value * | Storage, |
DILocalVariable * | VarInfo, | ||
DIExpression * | Expr, | ||
const DILocation * | DL, | ||
Instruction * | InsertBefore | ||
) |
Insert a new llvm.dbg.declare intrinsic call.
Storage | llvm::Value of the variable |
VarInfo | Variable's debug info descriptor. |
Expr | A complex location expression. |
DL | Debug info location. |
InsertBefore | Location for the new intrinsic. |
Definition at line 958 of file DIBuilder.cpp.
References DL, and llvm::ilist_detail::node_parent_access< NodeTy, ParentTy >::getParent().
DbgInstPtr DIBuilder::insertLabel | ( | DILabel * | LabelInfo, |
const DILocation * | DL, | ||
BasicBlock * | InsertAtEnd | ||
) |
Insert a new llvm.dbg.label intrinsic call.
LabelInfo | Label's debug info descriptor. |
DL | Debug info location. |
InsertAtEnd | Location for the new intrinsic. |
Definition at line 1023 of file DIBuilder.cpp.
References DL.
DbgInstPtr DIBuilder::insertLabel | ( | DILabel * | LabelInfo, |
const DILocation * | DL, | ||
Instruction * | InsertBefore | ||
) |
Insert a new llvm.dbg.label intrinsic call.
LabelInfo | Label's debug info descriptor. |
DL | Debug info location. |
InsertBefore | Location for the new intrinsic. |
Definition at line 1016 of file DIBuilder.cpp.
References DL, and llvm::ilist_detail::node_parent_access< NodeTy, ParentTy >::getParent().
void DIBuilder::replaceArrays | ( | DICompositeType *& | T, |
DINodeArray | Elements, | ||
DINodeArray | TParams = DINodeArray() |
||
) |
Replace arrays on a composite type.
If T
is resolved, but the arrays aren't – which can happen if T
has a self-reference – DIBuilder needs to track the array to resolve cycles.
Definition at line 1209 of file DIBuilder.cpp.
References N.
Referenced by buildFrameDebugInfo(), and solveDIType().
|
inline |
Replace a temporary node.
Call MDNode::replaceAllUsesWith() on N
, replacing it with Replacement
.
If Replacement
is the same as N.get()
, instead call MDNode::replaceWithUniqued(). In this case, the uniqued node could have a different address, so we return the final address.
Definition at line 1061 of file DIBuilder.h.
References N, and llvm::MDNode::replaceWithUniqued().
Referenced by finalize().
void DIBuilder::replaceVTableHolder | ( | DICompositeType *& | T, |
DIType * | VTableHolder | ||
) |
Replace the vtable holder in the given type.
If this creates a self reference, it may orphan some unresolved cycles in the operands of T
, so DIBuilder needs to track that.
Definition at line 1190 of file DIBuilder.cpp.
References N.
void DIBuilder::retainType | ( | DIScope * | T | ) |
Retain DIScope* in a module even if it is not referenced through debug info anchors.
Definition at line 655 of file DIBuilder.cpp.
References assert().