|
LLVM
4.0.0
|
#include <DIBuilder.h>
Public Member Functions | |
| DIBuilder (Module &M, bool AllowUnresolved=true) | |
| Construct a builder for a module. More... | |
| DIBuilder (const DIBuilder &)=delete | |
| DIBuilder & | operator= (const DIBuilder &)=delete |
| void | finalize () |
| Construct any deferred debug info descriptors. More... | |
| 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) |
| A CompileUnit provides an anchor for all debugging information generated during this instance of compilation. More... | |
| DIFile * | createFile (StringRef Filename, StringRef Directory, DIFile::ChecksumKind CSKind=DIFile::CSK_None, StringRef Checksum=StringRef()) |
| Create a file descriptor to hold debugging information for a file. More... | |
| DIMacro * | createMacro (DIMacroFile *Parent, unsigned Line, unsigned MacroType, StringRef Name, StringRef Value=StringRef()) |
| Create debugging information entry for a macro. More... | |
| DIMacroFile * | createTempMacroFile (DIMacroFile *Parent, unsigned Line, DIFile *File) |
| Create debugging information temporary entry for a macro file. More... | |
| DIEnumerator * | createEnumerator (StringRef Name, int64_t Val) |
| Create a single enumerator value. More... | |
| DIBasicType * | createUnspecifiedType (StringRef Name) |
| Create a DWARF unspecified type. More... | |
| DIBasicType * | createNullPtrType () |
| Create C++11 nullptr type. More... | |
| DIBasicType * | createBasicType (StringRef Name, uint64_t SizeInBits, unsigned Encoding) |
| Create debugging information entry for a basic type. More... | |
| DIDerivedType * | createQualifiedType (unsigned Tag, DIType *FromTy) |
| Create debugging information entry for a qualified type, e.g. More... | |
| DIDerivedType * | createPointerType (DIType *PointeeTy, uint64_t SizeInBits, uint32_t AlignInBits=0, StringRef Name="") |
| Create debugging information entry for a pointer. More... | |
| 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. More... | |
| DIDerivedType * | createReferenceType (unsigned Tag, DIType *RTy, uint64_t SizeInBits=0, uint32_t AlignInBits=0) |
| Create debugging information entry for a c++ style reference or rvalue reference type. More... | |
| DIDerivedType * | createTypedef (DIType *Ty, StringRef Name, DIFile *File, unsigned LineNo, DIScope *Context) |
| Create debugging information entry for a typedef. More... | |
| DIDerivedType * | createFriend (DIType *Ty, DIType *FriendTy) |
| Create debugging information entry for a 'friend'. More... | |
| DIDerivedType * | createInheritance (DIType *Ty, DIType *BaseTy, uint64_t BaseOffset, DINode::DIFlags Flags) |
| Create debugging information entry to establish inheritance relationship between two types. More... | |
| DIDerivedType * | createMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint32_t AlignInBits, uint64_t OffsetInBits, DINode::DIFlags Flags, DIType *Ty) |
| Create debugging information entry for a member. More... | |
| DIDerivedType * | createBitFieldMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, uint64_t SizeInBits, uint64_t OffsetInBits, uint64_t StorageOffsetInBits, DINode::DIFlags Flags, DIType *Ty) |
| Create debugging information entry for a bit field member. More... | |
| DIDerivedType * | createStaticMemberType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, DIType *Ty, DINode::DIFlags Flags, Constant *Val, uint32_t AlignInBits=0) |
| Create debugging information entry for a C++ static data member. More... | |
| 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. More... | |
| DIObjCProperty * | createObjCProperty (StringRef Name, DIFile *File, unsigned LineNumber, StringRef GetterName, StringRef SetterName, unsigned PropertyAttributes, DIType *Ty) |
| Create debugging information entry for Objective-C property. More... | |
| 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, DIType *VTableHolder=nullptr, MDNode *TemplateParms=nullptr, StringRef UniqueIdentifier="") |
| Create debugging information entry for a class. More... | |
| 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="") |
| Create debugging information entry for a struct. More... | |
| 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. More... | |
| DITemplateTypeParameter * | createTemplateTypeParameter (DIScope *Scope, StringRef Name, DIType *Ty) |
| Create debugging information for template type parameter. More... | |
| DITemplateValueParameter * | createTemplateValueParameter (DIScope *Scope, StringRef Name, DIType *Ty, Constant *Val) |
| Create debugging information for template value parameter. More... | |
| DITemplateValueParameter * | createTemplateTemplateParameter (DIScope *Scope, StringRef Name, DIType *Ty, StringRef Val) |
| Create debugging information for a template template parameter. More... | |
| DITemplateValueParameter * | createTemplateParameterPack (DIScope *Scope, StringRef Name, DIType *Ty, DINodeArray Val) |
| Create debugging information for a template parameter pack. More... | |
| DICompositeType * | createArrayType (uint64_t Size, uint32_t AlignInBits, DIType *Ty, DINodeArray Subscripts) |
| Create debugging information entry for an array. More... | |
| DICompositeType * | createVectorType (uint64_t Size, uint32_t AlignInBits, DIType *Ty, DINodeArray Subscripts) |
| Create debugging information entry for a vector type. More... | |
| DICompositeType * | createEnumerationType (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber, uint64_t SizeInBits, uint32_t AlignInBits, DINodeArray Elements, DIType *UnderlyingType, StringRef UniqueIdentifier="") |
| Create debugging information entry for an enumeration. More... | |
| DISubroutineType * | createSubroutineType (DITypeRefArray ParameterTypes, DINode::DIFlags Flags=DINode::FlagZero, unsigned CC=0) |
| Create subroutine type. More... | |
| DICompositeType * | createExternalTypeRef (unsigned Tag, DIFile *File, StringRef UniqueIdentifier) |
| Create an external type reference. More... | |
| DIType * | createArtificialType (DIType *Ty) |
| Create a new DIType* with "artificial" flag set. More... | |
| DIType * | createObjectPointerType (DIType *Ty) |
| Create a new DIType* with the "object pointer" flag set. More... | |
| 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. More... | |
| 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="") |
| Create a temporary forward-declared type. More... | |
| void | retainType (DIScope *T) |
| Retain DIScope* in a module even if it is not referenced through debug info anchors. More... | |
| DIBasicType * | createUnspecifiedParameter () |
| Create unspecified parameter type for a subroutine type. More... | |
| DINodeArray | getOrCreateArray (ArrayRef< Metadata * > Elements) |
| Get a DINodeArray, create one if required. More... | |
| DIMacroNodeArray | getOrCreateMacroArray (ArrayRef< Metadata * > Elements) |
| Get a DIMacroNodeArray, create one if required. More... | |
| DITypeRefArray | getOrCreateTypeArray (ArrayRef< Metadata * > Elements) |
| Get a DITypeRefArray, create one if required. More... | |
| DISubrange * | getOrCreateSubrange (int64_t Lo, int64_t Count) |
| Create a descriptor for a value range. More... | |
| DIGlobalVariableExpression * | createGlobalVariableExpression (DIScope *Context, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DIType *Ty, bool isLocalToUnit, DIExpression *Expr=nullptr, MDNode *Decl=nullptr, uint32_t AlignInBits=0) |
| Create a new descriptor for the specified variable. More... | |
| DIGlobalVariable * | createTempGlobalVariableFwdDecl (DIScope *Context, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DIType *Ty, bool isLocalToUnit, MDNode *Decl=nullptr, uint32_t AlignInBits=0) |
| Identical to createGlobalVariable except that the resulting DbgNode is temporary and meant to be RAUWed. More... | |
| 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. More... | |
| DILocalVariable * | createParameterVariable (DIScope *Scope, StringRef Name, unsigned ArgNo, DIFile *File, unsigned LineNo, DIType *Ty, bool AlwaysPreserve=false, DINode::DIFlags Flags=DINode::FlagZero) |
| Create a new descriptor for a parameter variable. More... | |
| DIExpression * | createExpression (ArrayRef< uint64_t > Addr=None) |
| Create a new descriptor for the specified variable which has a complex address expression for its address. More... | |
| DIExpression * | createExpression (ArrayRef< int64_t > Addr) |
| DIExpression * | createFragmentExpression (unsigned OffsetInBits, unsigned SizeInBits) |
| Create a descriptor to describe one part of aggregate variable that is fragmented across multiple Values. More... | |
| DIExpression * | createConstantValueExpression (uint64_t Val) |
| Create an expression for a variable that does not have an address, but does have a constant value. More... | |
| DISubprogram * | createFunction (DIScope *Scope, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DISubroutineType *Ty, bool isLocalToUnit, bool isDefinition, unsigned ScopeLine, DINode::DIFlags Flags=DINode::FlagZero, bool isOptimized=false, DITemplateParameterArray TParams=nullptr, DISubprogram *Decl=nullptr) |
| Create a new descriptor for the specified subprogram. More... | |
| DISubprogram * | createTempFunctionFwdDecl (DIScope *Scope, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DISubroutineType *Ty, bool isLocalToUnit, bool isDefinition, unsigned ScopeLine, DINode::DIFlags Flags=DINode::FlagZero, bool isOptimized=false, DITemplateParameterArray TParams=nullptr, DISubprogram *Decl=nullptr) |
| Identical to createFunction, except that the resulting DbgNode is meant to be RAUWed. More... | |
| DISubprogram * | createMethod (DIScope *Scope, StringRef Name, StringRef LinkageName, DIFile *File, unsigned LineNo, DISubroutineType *Ty, bool isLocalToUnit, bool isDefinition, unsigned Virtuality=0, unsigned VTableIndex=0, int ThisAdjustment=0, DIType *VTableHolder=nullptr, DINode::DIFlags Flags=DINode::FlagZero, bool isOptimized=false, DITemplateParameterArray TParams=nullptr) |
| Create a new descriptor for the specified C++ method. More... | |
| DINamespace * | createNameSpace (DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNo, bool ExportSymbols) |
| This creates new descriptor for a namespace with the specified parent scope. More... | |
| DIModule * | createModule (DIScope *Scope, StringRef Name, StringRef ConfigurationMacros, StringRef IncludePath, StringRef ISysRoot) |
| This creates new descriptor for a module with the specified parent scope. More... | |
| DILexicalBlockFile * | createLexicalBlockFile (DIScope *Scope, DIFile *File, unsigned Discriminator=0) |
| This creates a descriptor for a lexical block with a new file attached. More... | |
| DILexicalBlock * | createLexicalBlock (DIScope *Scope, DIFile *File, unsigned Line, unsigned Col) |
| This creates a descriptor for a lexical block with the specified parent context. More... | |
| DIImportedEntity * | createImportedModule (DIScope *Context, DINamespace *NS, unsigned Line) |
| Create a descriptor for an imported module. More... | |
| DIImportedEntity * | createImportedModule (DIScope *Context, DIImportedEntity *NS, unsigned Line) |
| Create a descriptor for an imported module. More... | |
| DIImportedEntity * | createImportedModule (DIScope *Context, DIModule *M, unsigned Line) |
| Create a descriptor for an imported module. More... | |
| DIImportedEntity * | createImportedDeclaration (DIScope *Context, DINode *Decl, unsigned Line, StringRef Name="") |
| Create a descriptor for an imported function. More... | |
| Instruction * | insertDeclare (llvm::Value *Storage, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, BasicBlock *InsertAtEnd) |
| Insert a new llvm.dbg.declare intrinsic call. More... | |
| Instruction * | insertDeclare (llvm::Value *Storage, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, Instruction *InsertBefore) |
| Insert a new llvm.dbg.declare intrinsic call. More... | |
| Instruction * | insertDbgValueIntrinsic (llvm::Value *Val, uint64_t Offset, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, BasicBlock *InsertAtEnd) |
| Insert a new llvm.dbg.value intrinsic call. More... | |
| Instruction * | insertDbgValueIntrinsic (llvm::Value *Val, uint64_t Offset, DILocalVariable *VarInfo, DIExpression *Expr, const DILocation *DL, Instruction *InsertBefore) |
| Insert a new llvm.dbg.value intrinsic call. More... | |
| void | replaceVTableHolder (DICompositeType *&T, DICompositeType *VTableHolder) |
| Replace the vtable holder in the given composite type. More... | |
| void | replaceArrays (DICompositeType *&T, DINodeArray Elements, DINodeArray TParams=DINodeArray()) |
| Replace arrays on a composite type. More... | |
| template<class NodeTy > | |
| NodeTy * | replaceTemporary (TempMDNode &&N, NodeTy *Replacement) |
| Replace a temporary node. More... | |
Definition at line 42 of file DIBuilder.h.
Construct a builder for a module.
If AllowUnresolved, collect unresolved nodes attached to the module in order to resolve cycles during finalize().
Definition at line 27 of file DIBuilder.cpp.
| DICompositeType * DIBuilder::createArrayType | ( | uint64_t | Size, |
| uint32_t | AlignInBits, | ||
| DIType * | Ty, | ||
| DINodeArray | Subscripts | ||
| ) |
Create debugging information entry for an array.
| Size | Array size. |
| AlignInBits | Alignment. |
| Ty | Element type. |
| Subscripts | Subscripts. |
Definition at line 466 of file DIBuilder.cpp.
References llvm::MDNode::get().
Create a new DIType* with "artificial" flag set.
Definition at line 493 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 634 of file DIBuilder.cpp.
References createLocalVariable().
| DIBasicType * DIBuilder::createBasicType | ( | StringRef | Name, |
| uint64_t | SizeInBits, | ||
| unsigned | Encoding | ||
| ) |
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. |
Definition at line 235 of file DIBuilder.cpp.
References assert(), llvm::StringRef::empty(), and llvm::MDNode::get().
| 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 | ||
| ) |
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. |
Definition at line 315 of file DIBuilder.cpp.
References llvm::IntegerType::get(), llvm::ConstantInt::get(), llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), and getNonCompileUnitScope().
| 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, | ||
| 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. |
| 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 397 of file DIBuilder.cpp.
References assert(), llvm::MDNode::get(), and getNonCompileUnitScope().
| 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 |
||
| ) |
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. |
Definition at line 125 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 558 of file DIBuilder.h.
References llvm::MDNode::get().
| DICompositeType * DIBuilder::createEnumerationType | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| DIFile * | File, | ||
| unsigned | LineNumber, | ||
| uint64_t | SizeInBits, | ||
| uint32_t | AlignInBits, | ||
| DINodeArray | Elements, | ||
| DIType * | UnderlyingType, | ||
| StringRef | UniqueIdentifier = "" |
||
| ) |
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. |
| UniqueIdentifier | A unique identifier for the enum. |
Definition at line 453 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| DIEnumerator * DIBuilder::createEnumerator | ( | StringRef | Name, |
| int64_t | Val | ||
| ) |
Create a single enumerator value.
Definition at line 221 of file DIBuilder.cpp.
References assert(), llvm::StringRef::empty(), and llvm::MDNode::get().
| DIExpression * DIBuilder::createExpression | ( | ArrayRef< uint64_t > | Addr = None | ) |
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 653 of file DIBuilder.cpp.
References llvm::MDNode::get().
Referenced by BuildReplacementDIExpr(), llvm::ConvertDebugDeclareToDebugValue(), createExpression(), and replaceOneDbgValueForAlloca().
| DIExpression * DIBuilder::createExpression | ( | ArrayRef< int64_t > | Addr | ) |
Definition at line 657 of file DIBuilder.cpp.
References llvm::ArrayRef< T >::begin(), createExpression(), and llvm::ArrayRef< T >::end().
| DICompositeType * DIBuilder::createExternalTypeRef | ( | unsigned | Tag, |
| DIFile * | File, | ||
| StringRef | UniqueIdentifier | ||
| ) |
Create an external type reference.
| Tag | Dwarf TAG. |
| File | File in which the type is defined. |
| UniqueIdentifier | A unique identifier for the type. |
Definition at line 445 of file DIBuilder.cpp.
References assert(), llvm::StringRef::empty(), and llvm::MDNode::get().
| DIFile * DIBuilder::createFile | ( | StringRef | Filename, |
| StringRef | Directory, | ||
| DIFile::ChecksumKind | CSKind = DIFile::CSK_None, |
||
| StringRef | Checksum = StringRef() |
||
| ) |
Create a file descriptor to hold debugging information for a file.
| Filename | File name. |
| Directory | Directory. |
| CSKind | Checksum kind (e.g. CSK_None, CSK_MD5, CSK_SHA1, etc.). |
| Checksum | Checksum data. |
Definition at line 191 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 519 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| DIExpression * DIBuilder::createFragmentExpression | ( | unsigned | OffsetInBits, |
| unsigned | SizeInBits | ||
| ) |
Create a descriptor to describe one part of aggregate variable that is fragmented across multiple Values.
| OffsetInBits | Offset of the piece in bits. |
| SizeInBits | Size of the piece in bits. |
Definition at line 663 of file DIBuilder.cpp.
References llvm::dwarf::DW_OP_LLVM_fragment, and llvm::MDNode::get().
| DIDerivedType * DIBuilder::createFriend | ( | DIType * | Ty, |
| DIType * | FriendTy | ||
| ) |
Create debugging information entry for a 'friend'.
Definition at line 283 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, | ||
| bool | isLocalToUnit, | ||
| bool | isDefinition, | ||
| unsigned | ScopeLine, | ||
| DINode::DIFlags | Flags = DINode::FlagZero, |
||
| bool | isOptimized = false, |
||
| DITemplateParameterArray | TParams = nullptr, |
||
| DISubprogram * | Decl = nullptr |
||
| ) |
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. |
| isLocalToUnit | True if this function is not externally visible. |
| isDefinition | True if this is a function definition. |
| 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. |
| isOptimized | True if optimization is ON. |
| TParams | Function template parameters. |
Definition at line 676 of file DIBuilder.cpp.
References getNonCompileUnitScope(), getSubprogram(), llvm::MDTuple::getTemporary(), llvm::None, and llvm::release.
| DIGlobalVariableExpression * DIBuilder::createGlobalVariableExpression | ( | DIScope * | Context, |
| StringRef | Name, | ||
| StringRef | LinkageName, | ||
| DIFile * | File, | ||
| unsigned | LineNo, | ||
| DIType * | Ty, | ||
| bool | isLocalToUnit, | ||
| DIExpression * | Expr = nullptr, |
||
| MDNode * | Decl = nullptr, |
||
| uint32_t | AlignInBits = 0 |
||
| ) |
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 580 of file DIBuilder.cpp.
References checkGlobalVariableScope(), llvm::MDNode::get(), llvm::MDNode::getDistinct(), and N.
| DIImportedEntity * DIBuilder::createImportedDeclaration | ( | DIScope * | Context, |
| DINode * | Decl, | ||
| unsigned | Line, | ||
| StringRef | Name = "" |
||
| ) |
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 |
| Line | Line number |
Definition at line 181 of file DIBuilder.cpp.
References createImportedModule().
| DIImportedEntity * DIBuilder::createImportedModule | ( | DIScope * | Context, |
| DINamespace * | NS, | ||
| unsigned | Line | ||
| ) |
Create a descriptor for an imported module.
| Context | The scope this module is imported into |
| NS | The namespace being imported here |
| Line | Line number |
Definition at line 161 of file DIBuilder.cpp.
References createImportedModule().
| DIImportedEntity * DIBuilder::createImportedModule | ( | DIScope * | Context, |
| DIImportedEntity * | NS, | ||
| unsigned | Line | ||
| ) |
Create a descriptor for an imported module.
| Context | The scope this module is imported into |
| NS | An aliased namespace |
| Line | Line number |
Definition at line 168 of file DIBuilder.cpp.
References createImportedModule().
| DIImportedEntity * DIBuilder::createImportedModule | ( | DIScope * | Context, |
| DIModule * | M, | ||
| unsigned | Line | ||
| ) |
Create a descriptor for an imported module.
| Context | The scope this module is imported into |
| M | The module being imported here |
| Line | Line number |
Definition at line 175 of file DIBuilder.cpp.
References createImportedModule().
| DIDerivedType * DIBuilder::createInheritance | ( | DIType * | Ty, |
| DIType * | BaseTy, | ||
| uint64_t | BaseOffset, | ||
| 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. |
| Flags | Flags to describe inheritance attribute, e.g. private |
Definition at line 290 of file DIBuilder.cpp.
References assert(), and llvm::MDNode::get().
| 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 752 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 746 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 196 of file DIBuilder.cpp.
References assert(), llvm::dwarf::DW_MACINFO_define, llvm::dwarf::DW_MACINFO_undef, llvm::StringRef::empty(), and llvm::MDNode::get().
| 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 257 of file DIBuilder.cpp.
References 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 | ||
| ) |
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. |
Definition at line 298 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| DISubprogram * DIBuilder::createMethod | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| StringRef | LinkageName, | ||
| DIFile * | File, | ||
| unsigned | LineNo, | ||
| DISubroutineType * | Ty, | ||
| bool | isLocalToUnit, | ||
| bool | isDefinition, | ||
| unsigned | Virtuality = 0, |
||
| unsigned | VTableIndex = 0, |
||
| int | ThisAdjustment = 0, |
||
| DIType * | VTableHolder = nullptr, |
||
| DINode::DIFlags | Flags = DINode::FlagZero, |
||
| bool | isOptimized = false, |
||
| DITemplateParameterArray | TParams = 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. |
| isLocalToUnit | True if this function is not externally visible.. |
| isDefinition | True if this is a function definition. |
| Virtuality | Attributes describing virtualness. e.g. pure virtual function. |
| 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. |
| isOptimized | True if optimization is ON. |
| TParams | Function template parameters. |
Definition at line 707 of file DIBuilder.cpp.
References assert(), getNonCompileUnitScope(), and getSubprogram().
| DIModule * DIBuilder::createModule | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| StringRef | ConfigurationMacros, | ||
| StringRef | IncludePath, | ||
| StringRef | ISysRoot | ||
| ) |
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. |
| ISysRoot | The clang system root (value of -isysroot). |
Definition at line 738 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| DINamespace * DIBuilder::createNameSpace | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| DIFile * | File, | ||
| unsigned | LineNo, | ||
| bool | ExportSymbols | ||
| ) |
This creates new descriptor for a namespace with the specified parent scope.
| Scope | Namespace scope |
| Name | Name of this namespace |
| File | Source file |
| LineNo | Line number |
| ExportSymbols | True for C++ inline namespaces. |
Definition at line 731 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| DIBasicType * DIBuilder::createNullPtrType | ( | ) |
Create C++11 nullptr type.
Definition at line 231 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 340 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| 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 351 of file DIBuilder.cpp.
References llvm::MDNode::get().
Create a new DIType* with the "object pointer" flag set.
Definition at line 500 of file DIBuilder.cpp.
References createTypeWithFlags(), fuzzer::Flags, 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 |
||
| ) |
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 644 of file DIBuilder.cpp.
References assert(), and createLocalVariable().
| DIDerivedType * DIBuilder::createPointerType | ( | DIType * | PointeeTy, |
| uint64_t | SizeInBits, | ||
| uint32_t | AlignInBits = 0, |
||
| StringRef | Name = "" |
||
| ) |
Create debugging information entry for a pointer.
| PointeeTy | Type pointed by this pointer. |
| SizeInBits | Size. |
| AlignInBits | Alignment. (optional) |
| Name | Pointer type name. (optional) |
Definition at line 247 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 242 of file DIBuilder.cpp.
References llvm::MDNode::get().
| DIDerivedType * DIBuilder::createReferenceType | ( | unsigned | Tag, |
| DIType * | RTy, | ||
| uint64_t | SizeInBits = 0, |
||
| uint32_t | AlignInBits = 0 |
||
| ) |
Create debugging information entry for a c++ style reference or rvalue reference type.
Definition at line 267 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 = "" |
||
| ) |
Create a temporary forward-declared type.
Definition at line 533 of file DIBuilder.cpp.
References getNonCompileUnitScope(), and llvm::MDNode::getTemporary().
| DIDerivedType * DIBuilder::createStaticMemberType | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| DIFile * | File, | ||
| unsigned | LineNo, | ||
| DIType * | Ty, | ||
| DINode::DIFlags | Flags, | ||
| llvm::Constant * | Val, | ||
| 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. |
| AlignInBits | Member alignment. |
Definition at line 329 of file DIBuilder.cpp.
References llvm::MDNode::get(), getConstantOrNull(), and getNonCompileUnitScope().
| 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 = "" |
||
| ) |
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. |
Definition at line 414 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| 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 439 of file DIBuilder.cpp.
References llvm::MDNode::get().
| DISubprogram * DIBuilder::createTempFunctionFwdDecl | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| StringRef | LinkageName, | ||
| DIFile * | File, | ||
| unsigned | LineNo, | ||
| DISubroutineType * | Ty, | ||
| bool | isLocalToUnit, | ||
| bool | isDefinition, | ||
| unsigned | ScopeLine, | ||
| DINode::DIFlags | Flags = DINode::FlagZero, |
||
| bool | isOptimized = false, |
||
| DITemplateParameterArray | TParams = nullptr, |
||
| DISubprogram * | Decl = nullptr |
||
| ) |
Identical to createFunction, except that the resulting DbgNode is meant to be RAUWed.
Definition at line 694 of file DIBuilder.cpp.
References getNonCompileUnitScope(), and llvm::MDNode::getTemporary().
| DIGlobalVariable * DIBuilder::createTempGlobalVariableFwdDecl | ( | DIScope * | Context, |
| StringRef | Name, | ||
| StringRef | LinkageName, | ||
| DIFile * | File, | ||
| unsigned | LineNo, | ||
| DIType * | Ty, | ||
| bool | isLocalToUnit, | ||
| MDNode * | Decl = nullptr, |
||
| uint32_t | AlignInBits = 0 |
||
| ) |
Identical to createGlobalVariable except that the resulting DbgNode is temporary and meant to be RAUWed.
Definition at line 595 of file DIBuilder.cpp.
References checkGlobalVariableScope(), and llvm::MDNode::getTemporary().
| 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 390 of file DIBuilder.cpp.
References createTemplateValueParameterHelper(), and llvm::MDNode::get().
| DITemplateValueParameter * DIBuilder::createTemplateTemplateParameter | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| DIType * | Ty, | ||
| StringRef | Val | ||
| ) |
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. |
Definition at line 382 of file DIBuilder.cpp.
References createTemplateValueParameterHelper(), and llvm::MDString::get().
| DITemplateTypeParameter * DIBuilder::createTemplateTypeParameter | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| DIType * | Ty | ||
| ) |
Create debugging information for template type parameter.
| Scope | Scope in which this type is defined. |
| Name | Type parameter name. |
| Ty | Parameter type. |
Definition at line 359 of file DIBuilder.cpp.
References assert(), and llvm::MDNode::get().
| DITemplateValueParameter * DIBuilder::createTemplateValueParameter | ( | DIScope * | Scope, |
| StringRef | Name, | ||
| DIType * | Ty, | ||
| Constant * | Val | ||
| ) |
Create debugging information for template value parameter.
| Scope | Scope in which this type is defined. |
| Name | Value parameter name. |
| Ty | Parameter type. |
| Val | Constant parameter value. |
Definition at line 374 of file DIBuilder.cpp.
References createTemplateValueParameterHelper(), and getConstantOrNull().
| 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 208 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 | ||
| ) |
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. |
Definition at line 275 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| 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 427 of file DIBuilder.cpp.
References llvm::MDNode::get(), and getNonCompileUnitScope().
| DIBasicType * DIBuilder::createUnspecifiedParameter | ( | ) |
Create unspecified parameter type for a subroutine type.
Definition at line 516 of file DIBuilder.cpp.
| DIBasicType * DIBuilder::createUnspecifiedType | ( | StringRef | Name | ) |
Create a DWARF unspecified type.
Definition at line 226 of file DIBuilder.cpp.
References assert(), llvm::StringRef::empty(), and llvm::MDNode::get().
Referenced by createNullPtrType().
| 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 476 of file DIBuilder.cpp.
References llvm::MDNode::get().
| void DIBuilder::finalize | ( | ) |
Construct any deferred debug info descriptors.
Definition at line 42 of file DIBuilder.cpp.
References llvm::SmallVectorImpl< T >::append(), assert(), llvm::dwarf::DW_MACINFO_start_file, E, llvm::SmallVectorBase::empty(), llvm::MDNode::get(), llvm::MDTuple::get(), getOrCreateArray(), getOrCreateMacroArray(), I, llvm::SmallPtrSetImpl< PtrType >::insert(), llvm::MDNode::isResolved(), llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), llvm::DICompileUnit::replaceEnumTypes(), llvm::DICompileUnit::replaceGlobalVariables(), llvm::DICompileUnit::replaceImportedEntities(), llvm::DICompileUnit::replaceMacros(), llvm::DICompileUnit::replaceRetainedTypes(), replaceTemporary(), and llvm::MDNode::resolveCycles().
Get a DINodeArray, create one if required.
Definition at line 547 of file DIBuilder.cpp.
References llvm::MDTuple::get().
Referenced by finalize().
Get a DIMacroNodeArray, create one if required.
Definition at line 552 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 567 of file DIBuilder.cpp.
References llvm::MDNode::get().
| DITypeRefArray DIBuilder::getOrCreateTypeArray | ( | ArrayRef< Metadata * > | Elements | ) |
Get a DITypeRefArray, create one if required.
Definition at line 556 of file DIBuilder.cpp.
References llvm::MDNode::get(), i, llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), and llvm::ArrayRef< T >::size().
| Instruction * DIBuilder::insertDbgValueIntrinsic | ( | llvm::Value * | Val, |
| uint64_t | Offset, | ||
| DILocalVariable * | VarInfo, | ||
| DIExpression * | Expr, | ||
| const DILocation * | DL, | ||
| BasicBlock * | InsertAtEnd | ||
| ) |
Insert a new llvm.dbg.value intrinsic call.
| Val | llvm::Value of the variable |
| Offset | Offset |
| VarInfo | Variable's debug info descriptor. |
| Expr | A complex location expression. |
| DL | Debug info location. |
| InsertAtEnd | Location for the new intrinsic. |
Definition at line 836 of file DIBuilder.cpp.
References AMDGPU::RuntimeMD::KeyName::Args, assert(), llvm::CallInst::Create(), llvm::ConstantInt::get(), llvm::MetadataAsValue::get(), getDbgIntrinsicValueImpl(), llvm::Intrinsic::getDeclaration(), llvm::Type::getInt64Ty(), llvm::DILocalVariable::getScope(), llvm::DILocalScope::getSubprogram(), and withDebugLoc().
Referenced by llvm::ConvertDebugDeclareToDebugValue(), and replaceOneDbgValueForAlloca().
| Instruction * DIBuilder::insertDbgValueIntrinsic | ( | llvm::Value * | Val, |
| uint64_t | Offset, | ||
| DILocalVariable * | VarInfo, | ||
| DIExpression * | Expr, | ||
| const DILocation * | DL, | ||
| Instruction * | InsertBefore | ||
| ) |
Insert a new llvm.dbg.value intrinsic call.
| Val | llvm::Value of the variable |
| Offset | Offset |
| VarInfo | Variable's debug info descriptor. |
| Expr | A complex location expression. |
| DL | Debug info location. |
| InsertBefore | Location for the new intrinsic. |
Definition at line 813 of file DIBuilder.cpp.
References AMDGPU::RuntimeMD::KeyName::Args, assert(), llvm::CallInst::Create(), llvm::ConstantInt::get(), llvm::MetadataAsValue::get(), getDbgIntrinsicValueImpl(), llvm::Intrinsic::getDeclaration(), llvm::Type::getInt64Ty(), llvm::DILocalVariable::getScope(), llvm::DILocalScope::getSubprogram(), and withDebugLoc().
| Instruction * 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 789 of file DIBuilder.cpp.
References AMDGPU::RuntimeMD::KeyName::Args, assert(), llvm::CallInst::Create(), llvm::MetadataAsValue::get(), getDbgIntrinsicValueImpl(), llvm::Intrinsic::getDeclaration(), llvm::DILocalVariable::getScope(), llvm::DILocalScope::getSubprogram(), llvm::BasicBlock::getTerminator(), and withDebugLoc().
Referenced by llvm::replaceDbgDeclare().
| Instruction * 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 770 of file DIBuilder.cpp.
References AMDGPU::RuntimeMD::KeyName::Args, assert(), llvm::CallInst::Create(), llvm::MetadataAsValue::get(), getDbgIntrinsicValueImpl(), llvm::Intrinsic::getDeclaration(), llvm::DILocalVariable::getScope(), llvm::DILocalScope::getSubprogram(), and withDebugLoc().
| 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 880 of file DIBuilder.cpp.
References llvm::TypedTrackingMDRef< T >::get(), llvm::MDNode::isResolved(), N, llvm::DICompositeType::replaceElements(), and llvm::DICompositeType::replaceTemplateParams().
|
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 770 of file DIBuilder.h.
References llvm::MDNode::get(), llvm::MDNode::replaceAllUsesWith(), and llvm::MDNode::replaceWithUniqued().
Referenced by finalize().
| void DIBuilder::replaceVTableHolder | ( | DICompositeType *& | T, |
| DICompositeType * | VTableHolder | ||
| ) |
Replace the vtable holder in the given composite 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 860 of file DIBuilder.cpp.
References llvm::TypedTrackingMDRef< T >::get(), llvm::MDNode::isResolved(), N, llvm::MDNode::operands(), and llvm::DICompositeType::replaceVTableHolder().
| void DIBuilder::retainType | ( | DIScope * | T | ) |
Retain DIScope* in a module even if it is not referenced through debug info anchors.
Definition at line 508 of file DIBuilder.cpp.
References assert().
1.8.6