rocm.bindings.llvm.c.cydebuginfo#
2026-09-24
36 min read time
Applies to Linux and Windows
Advanced Micro Devices, Inc.
Cython declarations for the C-level interface. Use
cimport rocm.bindings.llvm.c.cydebuginfo from your Cython code to access
these declarations directly.
See also
The high-level Python API is documented at rocm.bindings.llvm.c.debuginfo.
# MIT License
#
# Copyright (c) 2021-2026 Advanced Micro Devices, Inc.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
# This file has been autogenerated, do not modify.
from libc.stdint cimport *
ctypedef bint _Bool # bool is not a reserved keyword in C, _Bool is
from rocm.bindings.llvm.c.cytypes cimport *
from rocm.bindings.llvm.c.cyvisibility cimport *
cdef extern from "llvm-c/DebugInfo.h":
ctypedef enum LLVMDIFlags:
LLVMDIFlagZero
LLVMDIFlagPrivate
LLVMDIFlagProtected
LLVMDIFlagPublic
LLVMDIFlagFwdDecl
LLVMDIFlagAppleBlock
LLVMDIFlagReservedBit4
LLVMDIFlagVirtual
LLVMDIFlagArtificial
LLVMDIFlagExplicit
LLVMDIFlagPrototyped
LLVMDIFlagObjcClassComplete
LLVMDIFlagObjectPointer
LLVMDIFlagVector
LLVMDIFlagStaticMember
LLVMDIFlagLValueReference
LLVMDIFlagRValueReference
LLVMDIFlagReserved
LLVMDIFlagSingleInheritance
LLVMDIFlagMultipleInheritance
LLVMDIFlagVirtualInheritance
LLVMDIFlagIntroducedVirtual
LLVMDIFlagBitField
LLVMDIFlagNoReturn
LLVMDIFlagTypePassByValue
LLVMDIFlagTypePassByReference
LLVMDIFlagEnumClass
LLVMDIFlagFixedEnum
LLVMDIFlagThunk
LLVMDIFlagNonTrivial
LLVMDIFlagBigEndian
LLVMDIFlagLittleEndian
LLVMDIFlagIndirectVirtualBase
LLVMDIFlagAccessibility
LLVMDIFlagPtrToMemberRep
ctypedef enum LLVMDWARFSourceLanguage:
LLVMDWARFSourceLanguageC89
LLVMDWARFSourceLanguageC
LLVMDWARFSourceLanguageAda83
LLVMDWARFSourceLanguageC_plus_plus
LLVMDWARFSourceLanguageCobol74
LLVMDWARFSourceLanguageCobol85
LLVMDWARFSourceLanguageFortran77
LLVMDWARFSourceLanguageFortran90
LLVMDWARFSourceLanguagePascal83
LLVMDWARFSourceLanguageModula2
LLVMDWARFSourceLanguageJava
LLVMDWARFSourceLanguageC99
LLVMDWARFSourceLanguageAda95
LLVMDWARFSourceLanguageFortran95
LLVMDWARFSourceLanguagePLI
LLVMDWARFSourceLanguageObjC
LLVMDWARFSourceLanguageObjC_plus_plus
LLVMDWARFSourceLanguageUPC
LLVMDWARFSourceLanguageD
LLVMDWARFSourceLanguagePython
LLVMDWARFSourceLanguageOpenCL
LLVMDWARFSourceLanguageGo
LLVMDWARFSourceLanguageModula3
LLVMDWARFSourceLanguageHaskell
LLVMDWARFSourceLanguageC_plus_plus_03
LLVMDWARFSourceLanguageC_plus_plus_11
LLVMDWARFSourceLanguageOCaml
LLVMDWARFSourceLanguageRust
LLVMDWARFSourceLanguageC11
LLVMDWARFSourceLanguageSwift
LLVMDWARFSourceLanguageJulia
LLVMDWARFSourceLanguageDylan
LLVMDWARFSourceLanguageC_plus_plus_14
LLVMDWARFSourceLanguageFortran03
LLVMDWARFSourceLanguageFortran08
LLVMDWARFSourceLanguageRenderScript
LLVMDWARFSourceLanguageBLISS
LLVMDWARFSourceLanguageKotlin
LLVMDWARFSourceLanguageZig
LLVMDWARFSourceLanguageCrystal
LLVMDWARFSourceLanguageC_plus_plus_17
LLVMDWARFSourceLanguageC_plus_plus_20
LLVMDWARFSourceLanguageC17
LLVMDWARFSourceLanguageFortran18
LLVMDWARFSourceLanguageAda2005
LLVMDWARFSourceLanguageAda2012
LLVMDWARFSourceLanguageHIP
LLVMDWARFSourceLanguageAssembly
LLVMDWARFSourceLanguageC_sharp
LLVMDWARFSourceLanguageMojo
LLVMDWARFSourceLanguageGLSL
LLVMDWARFSourceLanguageGLSL_ES
LLVMDWARFSourceLanguageHLSL
LLVMDWARFSourceLanguageOpenCL_CPP
LLVMDWARFSourceLanguageCPP_for_OpenCL
LLVMDWARFSourceLanguageSYCL
LLVMDWARFSourceLanguageRuby
LLVMDWARFSourceLanguageMove
LLVMDWARFSourceLanguageHylo
LLVMDWARFSourceLanguageMetal
LLVMDWARFSourceLanguageMips_Assembler
LLVMDWARFSourceLanguageGOOGLE_RenderScript
LLVMDWARFSourceLanguageBORLAND_Delphi
ctypedef unsigned int LLVMDWARFMemorySpace
ctypedef enum LLVMDWARFEmissionKind:
LLVMDWARFEmissionNone
LLVMDWARFEmissionFull
LLVMDWARFEmissionLineTablesOnly
cdef enum:
LLVMMDStringMetadataKind
LLVMConstantAsMetadataMetadataKind
LLVMLocalAsMetadataMetadataKind
LLVMDistinctMDOperandPlaceholderMetadataKind
LLVMMDTupleMetadataKind
LLVMDILocationMetadataKind
LLVMDIExpressionMetadataKind
LLVMDIGlobalVariableExpressionMetadataKind
LLVMGenericDINodeMetadataKind
LLVMDISubrangeMetadataKind
LLVMDIEnumeratorMetadataKind
LLVMDIBasicTypeMetadataKind
LLVMDIDerivedTypeMetadataKind
LLVMDICompositeTypeMetadataKind
LLVMDISubroutineTypeMetadataKind
LLVMDIFileMetadataKind
LLVMDICompileUnitMetadataKind
LLVMDISubprogramMetadataKind
LLVMDILexicalBlockMetadataKind
LLVMDILexicalBlockFileMetadataKind
LLVMDINamespaceMetadataKind
LLVMDIModuleMetadataKind
LLVMDITemplateTypeParameterMetadataKind
LLVMDITemplateValueParameterMetadataKind
LLVMDIGlobalVariableMetadataKind
LLVMDILocalVariableMetadataKind
LLVMDILabelMetadataKind
LLVMDIObjCPropertyMetadataKind
LLVMDIImportedEntityMetadataKind
LLVMDIMacroMetadataKind
LLVMDIMacroFileMetadataKind
LLVMDICommonBlockMetadataKind
LLVMDIStringTypeMetadataKind
LLVMDIGenericSubrangeMetadataKind
LLVMDIArgListMetadataKind
LLVMDIAssignIDMetadataKind
LLVMDISubrangeTypeMetadataKind
LLVMDIFixedPointTypeMetadataKind
ctypedef unsigned int LLVMMetadataKind
ctypedef enum LLVMChecksumKind:
CSK_MD5
CSK_SHA1
CSK_SHA256
ctypedef unsigned int LLVMDWARFTypeEncoding
ctypedef enum LLVMDWARFMacinfoRecordType:
LLVMDWARFMacinfoRecordTypeDefine
LLVMDWARFMacinfoRecordTypeMacro
LLVMDWARFMacinfoRecordTypeStartFile
LLVMDWARFMacinfoRecordTypeEndFile
LLVMDWARFMacinfoRecordTypeVendorExt
#
# The current debug metadata version number.
cdef unsigned int LLVMDebugMetadataVersion()
#
# The version of debug metadata that's present in the provided \c Module.
cdef unsigned int LLVMGetModuleDebugMetadataVersion(LLVMModuleRef Module)
#
# Strip debug info in the module if it exists.
# To do this, we remove all calls to the debugger intrinsics and any named
# metadata for debugging. We also remove debug locations for instructions.
# Return true if module is modified.
cdef int LLVMStripModuleDebugInfo(LLVMModuleRef Module)
#
# Construct a builder for a module, and do not allow for unresolved nodes
# attached to the module.
cdef LLVMDIBuilderRef LLVMCreateDIBuilderDisallowUnresolved(LLVMModuleRef M)
#
# Construct a builder for a module and collect unresolved nodes attached
# to the module in order to resolve cycles during a call to
# \c LLVMDIBuilderFinalize.
cdef LLVMDIBuilderRef LLVMCreateDIBuilder(LLVMModuleRef M)
#
# Deallocates the \c DIBuilder and everything it owns.
# @note You must call \c LLVMDIBuilderFinalize before this
cdef void LLVMDisposeDIBuilder(LLVMDIBuilderRef Builder)
#
# Construct any deferred debug info descriptors.
cdef void LLVMDIBuilderFinalize(LLVMDIBuilderRef Builder)
#
# Finalize a specific subprogram.
# No new variables may be added to this subprogram afterwards.
cdef void LLVMDIBuilderFinalizeSubprogram(LLVMDIBuilderRef Builder,LLVMMetadataRef Subprogram)
#
# A CompileUnit provides an anchor for all debugging
# information generated during this instance of compilation.
# \param Lang Source programming language, eg.
# \c LLVMDWARFSourceLanguageC99
# \param FileRef File info.
# \param Producer Identify the producer of debugging information
# and code. Usually this is a compiler
# version string.
# \param ProducerLen The length of the C string passed to \c Producer.
# \param isOptimized A boolean flag which indicates whether optimization
# is enabled or not.
# \param 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.
# \param FlagsLen The length of the C string passed to \c Flags.
# \param RuntimeVer This indicates runtime version for languages like
# Objective-C.
# \param SplitName The name of the file that we'll split debug info
# out into.
# \param SplitNameLen The length of the C string passed to \c SplitName.
# \param Kind The kind of debug information to generate.
# \param DWOId The DWOId if this is a split skeleton compile unit.
# \param SplitDebugInlining Whether to emit inline debug info.
# \param DebugInfoForProfiling Whether to emit extra debug info for
# profile collection.
# \param SysRoot The Clang system root (value of -isysroot).
# \param SysRootLen The length of the C string passed to \c SysRoot.
# \param SDK The SDK. On Darwin, the last component of the sysroot.
# \param SDKLen The length of the C string passed to \c SDK.
cdef LLVMMetadataRef LLVMDIBuilderCreateCompileUnit(LLVMDIBuilderRef Builder,LLVMDWARFSourceLanguage Lang,LLVMMetadataRef FileRef,const char * Producer,size_t ProducerLen,int isOptimized,const char * Flags,size_t FlagsLen,unsigned int RuntimeVer,const char * SplitName,size_t SplitNameLen,LLVMDWARFEmissionKind Kind,unsigned int DWOId,int SplitDebugInlining,int DebugInfoForProfiling,const char * SysRoot,size_t SysRootLen,const char * SDK,size_t SDKLen)
#
# Create a file descriptor to hold debugging information for a file.
# \param Builder The \c DIBuilder.
# \param Filename File name.
# \param FilenameLen The length of the C string passed to \c Filename.
# \param Directory Directory.
# \param DirectoryLen The length of the C string passed to \c Directory.
cdef LLVMMetadataRef LLVMDIBuilderCreateFile(LLVMDIBuilderRef Builder,const char * Filename,size_t FilenameLen,const char * Directory,size_t DirectoryLen)
#
# Create a file descriptor to hold debugging information for a file.
# \param Builder The \c DIBuilder.
# \param Filename File name.
# \param FilenameLen The length of the C string passed to \c Filename.
# \param Directory Directory.
# \param DirectoryLen The length of the C string passed to \c Directory.
# \param ChecksumKind The kind of checksum. eg MD5, SHA256
# \param Checksum The checksum.
# \param ChecksumLen The length of the checksum.
# \param Souce The embedded source.
# \param SourceLen The length of the source.
cdef LLVMMetadataRef LLVMDIBuilderCreateFileWithChecksum(LLVMDIBuilderRef Builder,const char * Filename,size_t FilenameLen,const char * Directory,size_t DirectoryLen,LLVMChecksumKind ChecksumKind,const char * Checksum,size_t ChecksumLen,const char * Source,size_t SourceLen)
#
# Creates a new descriptor for a module with the specified parent scope.
# \param Builder The \c DIBuilder.
# \param ParentScope The parent scope containing this module declaration.
# \param Name Module name.
# \param NameLen The length of the C string passed to \c Name.
# \param ConfigMacros A space-separated shell-quoted list of -D macro
# definitions as they would appear on a command line.
# \param ConfigMacrosLen The length of the C string passed to \c ConfigMacros.
# \param IncludePath The path to the module map file.
# \param IncludePathLen The length of the C string passed to \c IncludePath.
# \param APINotesFile The path to an API notes file for the module.
# \param APINotesFileLen The length of the C string passed to \c APINotestFile.
cdef LLVMMetadataRef LLVMDIBuilderCreateModule(LLVMDIBuilderRef Builder,LLVMMetadataRef ParentScope,const char * Name,size_t NameLen,const char * ConfigMacros,size_t ConfigMacrosLen,const char * IncludePath,size_t IncludePathLen,const char * APINotesFile,size_t APINotesFileLen)
#
# Creates a new descriptor for a namespace with the specified parent scope.
# \param Builder The \c DIBuilder.
# \param ParentScope The parent scope containing this module declaration.
# \param Name NameSpace name.
# \param NameLen The length of the C string passed to \c Name.
# \param ExportSymbols Whether or not the namespace exports symbols, e.g.
# this is true of C++ inline namespaces.
cdef LLVMMetadataRef LLVMDIBuilderCreateNameSpace(LLVMDIBuilderRef Builder,LLVMMetadataRef ParentScope,const char * Name,size_t NameLen,int ExportSymbols)
#
# Create a new descriptor for the specified subprogram.
# \param Builder The \c DIBuilder.
# \param Scope Function scope.
# \param Name Function name.
# \param NameLen Length of enumeration name.
# \param LinkageName Mangled function name.
# \param LinkageNameLen Length of linkage name.
# \param File File where this variable is defined.
# \param LineNo Line number.
# \param Ty Function type.
# \param IsLocalToUnit True if this function is not externally visible.
# \param IsDefinition True if this is a function definition.
# \param ScopeLine Set to the beginning of the scope this starts
# \param Flags E.g.: \c LLVMDIFlagLValueReference. These flags are
# used to emit dwarf attributes.
# \param IsOptimized True if optimization is ON.
cdef LLVMMetadataRef LLVMDIBuilderCreateFunction(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,const char * LinkageName,size_t LinkageNameLen,LLVMMetadataRef File,unsigned int LineNo,LLVMMetadataRef Ty,int IsLocalToUnit,int IsDefinition,unsigned int ScopeLine,LLVMDIFlags Flags,int IsOptimized)
#
# Create a descriptor for a lexical block with the specified parent context.
# \param Builder The \c DIBuilder.
# \param Scope Parent lexical block.
# \param File Source file.
# \param Line The line in the source file.
# \param Column The column in the source file.
cdef LLVMMetadataRef LLVMDIBuilderCreateLexicalBlock(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,LLVMMetadataRef File,unsigned int Line,unsigned int Column)
#
# Create a descriptor for a lexical block with a new file attached.
# \param Builder The \c DIBuilder.
# \param Scope Lexical block.
# \param File Source file.
# \param Discriminator DWARF path discriminator value.
cdef LLVMMetadataRef LLVMDIBuilderCreateLexicalBlockFile(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,LLVMMetadataRef File,unsigned int Discriminator)
#
# Create a descriptor for an imported namespace. Suitable for e.g. C++
# using declarations.
# \param Builder The \c DIBuilder.
# \param Scope The scope this module is imported into
# \param File File where the declaration is located.
# \param Line Line number of the declaration.
cdef LLVMMetadataRef LLVMDIBuilderCreateImportedModuleFromNamespace(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,LLVMMetadataRef NS,LLVMMetadataRef File,unsigned int Line)
#
# Create a descriptor for an imported module that aliases another
# imported entity descriptor.
# \param Builder The \c DIBuilder.
# \param Scope The scope this module is imported into
# \param ImportedEntity Previous imported entity to alias.
# \param File File where the declaration is located.
# \param Line Line number of the declaration.
# \param Elements Renamed elements.
# \param NumElements Number of renamed elements.
cdef LLVMMetadataRef LLVMDIBuilderCreateImportedModuleFromAlias(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,LLVMMetadataRef ImportedEntity,LLVMMetadataRef File,unsigned int Line,LLVMMetadataRef * Elements,unsigned int NumElements)
#
# Create a descriptor for an imported module.
# \param Builder The \c DIBuilder.
# \param Scope The scope this module is imported into
# \param M The module being imported here
# \param File File where the declaration is located.
# \param Line Line number of the declaration.
# \param Elements Renamed elements.
# \param NumElements Number of renamed elements.
cdef LLVMMetadataRef LLVMDIBuilderCreateImportedModuleFromModule(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,LLVMMetadataRef M,LLVMMetadataRef File,unsigned int Line,LLVMMetadataRef * Elements,unsigned int NumElements)
#
# Create a descriptor for an imported function, type, or variable. Suitable
# for e.g. FORTRAN-style USE declarations.
# \param Builder The DIBuilder.
# \param Scope The scope this module is imported into.
# \param Decl The declaration (or definition) of a function, type,
# or variable.
# \param File File where the declaration is located.
# \param Line Line number of the declaration.
# \param Name A name that uniquely identifies this imported
# declaration.
# \param NameLen The length of the C string passed to \c Name.
# \param Elements Renamed elements.
# \param NumElements Number of renamed elements.
cdef LLVMMetadataRef LLVMDIBuilderCreateImportedDeclaration(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,LLVMMetadataRef Decl,LLVMMetadataRef File,unsigned int Line,const char * Name,size_t NameLen,LLVMMetadataRef * Elements,unsigned int NumElements)
#
# Creates a new DebugLocation that describes a source location.
# \param Line The line in the source file.
# \param Column The column in the source file.
# \param Scope The scope in which the location resides.
# \param InlinedAt The scope where this location was inlined, if at all.
# (optional).
# \note If the item to which this location is attached cannot be
# attributed to a source line, pass 0 for the line and column.
cdef LLVMMetadataRef LLVMDIBuilderCreateDebugLocation(LLVMContextRef Ctx,unsigned int Line,unsigned int Column,LLVMMetadataRef Scope,LLVMMetadataRef InlinedAt)
#
# Get the line number of this debug location.
# \param Location The debug location.
#
# @see DILocation::getLine()
cdef unsigned int LLVMDILocationGetLine(LLVMMetadataRef Location)
#
# Get the column number of this debug location.
# \param Location The debug location.
#
# @see DILocation::getColumn()
cdef unsigned int LLVMDILocationGetColumn(LLVMMetadataRef Location)
#
# Get the local scope associated with this debug location.
# \param Location The debug location.
#
# @see DILocation::getScope()
cdef LLVMMetadataRef LLVMDILocationGetScope(LLVMMetadataRef Location)
#
# Get the "inline at" location associated with this debug location.
# \param Location The debug location.
#
# @see DILocation::getInlinedAt()
cdef LLVMMetadataRef LLVMDILocationGetInlinedAt(LLVMMetadataRef Location)
#
# Get the metadata of the file associated with a given scope.
# \param Scope The scope object.
#
# @see DIScope::getFile()
cdef LLVMMetadataRef LLVMDIScopeGetFile(LLVMMetadataRef Scope)
#
# Get the directory of a given file.
# \param File The file object.
# \param Len The length of the returned string.
#
# @see DIFile::getDirectory()
cdef const char * LLVMDIFileGetDirectory(LLVMMetadataRef File,unsigned int * Len)
#
# Get the name of a given file.
# \param File The file object.
# \param Len The length of the returned string.
#
# @see DIFile::getFilename()
cdef const char * LLVMDIFileGetFilename(LLVMMetadataRef File,unsigned int * Len)
#
# Get the source of a given file.
# \param File The file object.
# \param Len The length of the returned string.
#
# @see DIFile::getSource()
cdef const char * LLVMDIFileGetSource(LLVMMetadataRef File,unsigned int * Len)
#
# Create a type array.
# \param Builder The DIBuilder.
# \param Data The type elements.
# \param NumElements Number of type elements.
cdef LLVMMetadataRef LLVMDIBuilderGetOrCreateTypeArray(LLVMDIBuilderRef Builder,LLVMMetadataRef * Data,size_t NumElements)
#
# Create subroutine type.
# \param Builder The DIBuilder.
# \param File The file in which the subroutine resides.
# \param ParameterTypes An array of subroutine parameter types. This
# includes return type at 0th index.
# \param NumParameterTypes The number of parameter types in \c ParameterTypes
# \param Flags E.g.: \c LLVMDIFlagLValueReference.
# These flags are used to emit dwarf attributes.
cdef LLVMMetadataRef LLVMDIBuilderCreateSubroutineType(LLVMDIBuilderRef Builder,LLVMMetadataRef File,LLVMMetadataRef * ParameterTypes,unsigned int NumParameterTypes,LLVMDIFlags Flags)
#
# Create debugging information entry for a macro.
# @param Builder The DIBuilder.
# @param ParentMacroFile Macro parent (could be NULL).
# @param Line Source line number where the macro is defined.
# @param RecordType DW_MACINFO_define or DW_MACINFO_undef.
# @param Name Macro name.
# @param NameLen Macro name length.
# @param Value Macro value.
# @param ValueLen Macro value length.
cdef LLVMMetadataRef LLVMDIBuilderCreateMacro(LLVMDIBuilderRef Builder,LLVMMetadataRef ParentMacroFile,unsigned int Line,LLVMDWARFMacinfoRecordType RecordType,const char * Name,size_t NameLen,const char * Value,size_t ValueLen)
#
# Create debugging information temporary entry for a macro file.
# List of macro node direct children will be calculated by DIBuilder,
# using the \p ParentMacroFile relationship.
# @param Builder The DIBuilder.
# @param ParentMacroFile Macro parent (could be NULL).
# @param Line Source line number where the macro file is included.
# @param File File descriptor containing the name of the macro file.
cdef LLVMMetadataRef LLVMDIBuilderCreateTempMacroFile(LLVMDIBuilderRef Builder,LLVMMetadataRef ParentMacroFile,unsigned int Line,LLVMMetadataRef File)
#
# Create debugging information entry for an enumerator.
# @param Builder The DIBuilder.
# @param Name Enumerator name.
# @param NameLen Length of enumerator name.
# @param Value Enumerator value.
# @param IsUnsigned True if the value is unsigned.
cdef LLVMMetadataRef LLVMDIBuilderCreateEnumerator(LLVMDIBuilderRef Builder,const char * Name,size_t NameLen,int64_t Value,int IsUnsigned)
#
# Create debugging information entry for an enumerator of arbitrary precision.
# @param Builder The DIBuilder.
# @param Name Enumerator name.
# @param NameLen Length of enumerator name.
# @param SizeInBits Number of bits of the value.
# @param Words The words that make up the value.
# @param IsUnsigned True if the value is unsigned.
cdef LLVMMetadataRef LLVMDIBuilderCreateEnumeratorOfArbitraryPrecision(LLVMDIBuilderRef Builder,const char * Name,size_t NameLen,uint64_t SizeInBits,const uint64_t * Words,int IsUnsigned)
#
# Create debugging information entry for an enumeration.
# \param Builder The DIBuilder.
# \param Scope Scope in which this enumeration is defined.
# \param Name Enumeration name.
# \param NameLen Length of enumeration name.
# \param File File where this member is defined.
# \param LineNumber Line number.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param Elements Enumeration elements.
# \param NumElements Number of enumeration elements.
# \param ClassTy Underlying type of a C++11/ObjC fixed enum.
cdef LLVMMetadataRef LLVMDIBuilderCreateEnumerationType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,uint64_t SizeInBits,uint32_t AlignInBits,LLVMMetadataRef * Elements,unsigned int NumElements,LLVMMetadataRef ClassTy)
#
# Create debugging information entry for a union.
# \param Builder The DIBuilder.
# \param Scope Scope in which this union is defined.
# \param Name Union name.
# \param NameLen Length of union name.
# \param File File where this member is defined.
# \param LineNumber Line number.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param Flags Flags to encode member attribute, e.g. private
# \param Elements Union elements.
# \param NumElements Number of union elements.
# \param RunTimeLang Optional parameter, Objective-C runtime version.
# \param UniqueId A unique identifier for the union.
# \param UniqueIdLen Length of unique identifier.
cdef LLVMMetadataRef LLVMDIBuilderCreateUnionType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,uint64_t SizeInBits,uint32_t AlignInBits,LLVMDIFlags Flags,LLVMMetadataRef * Elements,unsigned int NumElements,unsigned int RunTimeLang,const char * UniqueId,size_t UniqueIdLen)
#
# Create debugging information entry for an array.
# \param Builder The DIBuilder.
# \param Size Array size.
# \param AlignInBits Alignment.
# \param Ty Element type.
# \param Subscripts Subscripts.
# \param NumSubscripts Number of subscripts.
cdef LLVMMetadataRef LLVMDIBuilderCreateArrayType(LLVMDIBuilderRef Builder,uint64_t Size,uint32_t AlignInBits,LLVMMetadataRef Ty,LLVMMetadataRef * Subscripts,unsigned int NumSubscripts)
#
# Create debugging information entry for a set.
# \param Builder The DIBuilder.
# \param Scope The scope in which the set is defined.
# \param Name A name that uniquely identifies this set.
# \param NameLen The length of the C string passed to \c Name.
# \param File File where the set is located.
# \param Line Line number of the declaration.
# \param SizeInBits Set size.
# \param AlignInBits Set alignment.
# \param BaseTy The base type of the set.
cdef LLVMMetadataRef LLVMDIBuilderCreateSetType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,uint64_t SizeInBits,uint32_t AlignInBits,LLVMMetadataRef BaseTy)
#
# Create a descriptor for a subrange with dynamic bounds.
# \param Builder The DIBuilder.
# \param Scope The scope in which the subrange is defined.
# \param Name A name that uniquely identifies this subrange.
# \param NameLen The length of the C string passed to \c Name.
# \param LineNo Line number.
# \param File File where the subrange is located.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param Flags Flags.
# \param BaseTy The base type of the subrange. eg integer or enumeration
# \param LowerBound Lower bound of the subrange.
# \param UpperBound Upper bound of the subrange.
# \param Stride Stride of the subrange.
# \param Bias Bias of the subrange.
cdef LLVMMetadataRef LLVMDIBuilderCreateSubrangeType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,unsigned int LineNo,LLVMMetadataRef File,uint64_t SizeInBits,uint32_t AlignInBits,LLVMDIFlags Flags,LLVMMetadataRef BaseTy,LLVMMetadataRef LowerBound,LLVMMetadataRef UpperBound,LLVMMetadataRef Stride,LLVMMetadataRef Bias)
#
# Create debugging information entry for a dynamic array.
# \param Builder The DIBuilder.
# \param Size Array size.
# \param AlignInBits Alignment.
# \param Ty Element type.
# \param Subscripts Subscripts.
# \param NumSubscripts Number of subscripts.
# \param DataLocation DataLocation. (DIVariable, DIExpression or NULL)
# \param Associated Associated. (DIVariable, DIExpression or NULL)
# \param Allocated Allocated. (DIVariable, DIExpression or NULL)
# \param Rank Rank. (DIVariable, DIExpression or NULL)
# \param BitStride BitStride.
cdef LLVMMetadataRef LLVMDIBuilderCreateDynamicArrayType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,unsigned int LineNo,LLVMMetadataRef File,uint64_t Size,uint32_t AlignInBits,LLVMMetadataRef Ty,LLVMMetadataRef * Subscripts,unsigned int NumSubscripts,LLVMMetadataRef DataLocation,LLVMMetadataRef Associated,LLVMMetadataRef Allocated,LLVMMetadataRef Rank,LLVMMetadataRef BitStride)
#
# Replace arrays.
#
# @see DIBuilder::replaceArrays()
cdef void LLVMReplaceArrays(LLVMDIBuilderRef Builder,LLVMMetadataRef * T,LLVMMetadataRef * Elements,unsigned int NumElements)
#
# Create debugging information entry for a vector type.
# \param Builder The DIBuilder.
# \param Size Vector size.
# \param AlignInBits Alignment.
# \param Ty Element type.
# \param Subscripts Subscripts.
# \param NumSubscripts Number of subscripts.
cdef LLVMMetadataRef LLVMDIBuilderCreateVectorType(LLVMDIBuilderRef Builder,uint64_t Size,uint32_t AlignInBits,LLVMMetadataRef Ty,LLVMMetadataRef * Subscripts,unsigned int NumSubscripts)
#
# Create a DWARF unspecified type.
# \param Builder The DIBuilder.
# \param Name The unspecified type's name.
# \param NameLen Length of type name.
cdef LLVMMetadataRef LLVMDIBuilderCreateUnspecifiedType(LLVMDIBuilderRef Builder,const char * Name,size_t NameLen)
#
# Create debugging information entry for a basic
# type.
# \param Builder The DIBuilder.
# \param Name Type name.
# \param NameLen Length of type name.
# \param SizeInBits Size of the type.
# \param Encoding DWARF encoding code, e.g. \c LLVMDWARFTypeEncoding_float.
# \param Flags Flags to encode optional attribute like endianity
cdef LLVMMetadataRef LLVMDIBuilderCreateBasicType(LLVMDIBuilderRef Builder,const char * Name,size_t NameLen,uint64_t SizeInBits,unsigned int Encoding,LLVMDIFlags Flags)
#
# Create debugging information entry for a pointer.
# \param Builder The DIBuilder.
# \param PointeeTy Type pointed by this pointer.
# \param SizeInBits Size.
# \param AlignInBits Alignment. (optional, pass 0 to ignore)
# \param AddressSpace DWARF address space. (optional, pass 0 to ignore)
# \param MemorySpace DWARF memory space (optional, pass 0 for none).
# \param Name Pointer type name. (optional)
# \param NameLen Length of pointer type name. (optional)
cdef LLVMMetadataRef LLVMDIBuilderCreatePointerType(LLVMDIBuilderRef Builder,LLVMMetadataRef PointeeTy,uint64_t SizeInBits,uint32_t AlignInBits,unsigned int AddressSpace,unsigned int MS,const char * Name,size_t NameLen)
#
# Create debugging information entry for a struct.
# \param Builder The DIBuilder.
# \param Scope Scope in which this struct is defined.
# \param Name Struct name.
# \param NameLen Struct name length.
# \param File File where this member is defined.
# \param LineNumber Line number.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param Flags Flags to encode member attribute, e.g. private
# \param Elements Struct elements.
# \param NumElements Number of struct elements.
# \param RunTimeLang Optional parameter, Objective-C runtime version.
# \param VTableHolder The object containing the vtable for the struct.
# \param UniqueId A unique identifier for the struct.
# \param UniqueIdLen Length of the unique identifier for the struct.
cdef LLVMMetadataRef LLVMDIBuilderCreateStructType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,uint64_t SizeInBits,uint32_t AlignInBits,LLVMDIFlags Flags,LLVMMetadataRef DerivedFrom,LLVMMetadataRef * Elements,unsigned int NumElements,unsigned int RunTimeLang,LLVMMetadataRef VTableHolder,const char * UniqueId,size_t UniqueIdLen)
#
# Create debugging information entry for a member.
# \param Builder The DIBuilder.
# \param Scope Member scope.
# \param Name Member name.
# \param NameLen Length of member name.
# \param File File where this member is defined.
# \param LineNo Line number.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param OffsetInBits Member offset.
# \param Flags Flags to encode member attribute, e.g. private
# \param Ty Parent type.
cdef LLVMMetadataRef LLVMDIBuilderCreateMemberType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNo,uint64_t SizeInBits,uint32_t AlignInBits,uint64_t OffsetInBits,LLVMDIFlags Flags,LLVMMetadataRef Ty)
#
# Create debugging information entry for a
# C++ static data member.
# \param Builder The DIBuilder.
# \param Scope Member scope.
# \param Name Member name.
# \param NameLen Length of member name.
# \param File File where this member is declared.
# \param LineNumber Line number.
# \param Type Type of the static member.
# \param Flags Flags to encode member attribute, e.g. private.
# \param ConstantVal Const initializer of the member.
# \param AlignInBits Member alignment.
cdef LLVMMetadataRef LLVMDIBuilderCreateStaticMemberType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,LLVMMetadataRef Type,LLVMDIFlags Flags,LLVMValueRef ConstantVal,uint32_t AlignInBits)
#
# Create debugging information entry for a pointer to member.
# \param Builder The DIBuilder.
# \param PointeeType Type pointed to by this pointer.
# \param ClassType Type for which this pointer points to members of.
# \param SizeInBits Size.
# \param AlignInBits Alignment.
# \param Flags Flags.
cdef LLVMMetadataRef LLVMDIBuilderCreateMemberPointerType(LLVMDIBuilderRef Builder,LLVMMetadataRef PointeeType,LLVMMetadataRef ClassType,uint64_t SizeInBits,uint32_t AlignInBits,LLVMDIFlags Flags)
#
# Create debugging information entry for Objective-C instance variable.
# \param Builder The DIBuilder.
# \param Name Member name.
# \param NameLen The length of the C string passed to \c Name.
# \param File File where this member is defined.
# \param LineNo Line number.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param OffsetInBits Member offset.
# \param Flags Flags to encode member attribute, e.g. private
# \param Ty Parent type.
# \param PropertyNode Property associated with this ivar.
cdef LLVMMetadataRef LLVMDIBuilderCreateObjCIVar(LLVMDIBuilderRef Builder,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNo,uint64_t SizeInBits,uint32_t AlignInBits,uint64_t OffsetInBits,LLVMDIFlags Flags,LLVMMetadataRef Ty,LLVMMetadataRef PropertyNode)
#
# Create debugging information entry for Objective-C property.
# \param Builder The DIBuilder.
# \param Name Property name.
# \param NameLen The length of the C string passed to \c Name.
# \param File File where this property is defined.
# \param LineNo Line number.
# \param GetterName Name of the Objective C property getter selector.
# \param GetterNameLen The length of the C string passed to \c GetterName.
# \param SetterName Name of the Objective C property setter selector.
# \param SetterNameLen The length of the C string passed to \c SetterName.
# \param PropertyAttributes Objective C property attributes.
# \param Ty Type.
cdef LLVMMetadataRef LLVMDIBuilderCreateObjCProperty(LLVMDIBuilderRef Builder,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNo,const char * GetterName,size_t GetterNameLen,const char * SetterName,size_t SetterNameLen,unsigned int PropertyAttributes,LLVMMetadataRef Ty)
#
# Create a uniqued DIType* clone with FlagObjectPointer. If \c Implicit
# is true, then also set FlagArtificial.
# \param Builder The DIBuilder.
# \param Type The underlying type to which this pointer points.
# \param Implicit Indicates whether this pointer was implicitly generated
# (i.e., not spelled out in source).
cdef LLVMMetadataRef LLVMDIBuilderCreateObjectPointerType(LLVMDIBuilderRef Builder,LLVMMetadataRef Type,int Implicit)
#
# Create debugging information entry for a qualified
# type, e.g. 'const int'.
# \param Builder The DIBuilder.
# \param Tag Tag identifying type,
# e.g. LLVMDWARFTypeQualifier_volatile_type
# \param Type Base Type.
cdef LLVMMetadataRef LLVMDIBuilderCreateQualifiedType(LLVMDIBuilderRef Builder,unsigned int Tag,LLVMMetadataRef Type)
#
# Create debugging information entry for a c++
# style reference or rvalue reference type.
# \param Builder The DIBuilder.
# \param Tag Tag identifying type,
# \param Type Base Type.
# \param AddressSpace DWARF address space. (optional, pass 0 to ignore)
# \param MemorySpace DWARF memory space (optional, pass 0 for none).
cdef LLVMMetadataRef LLVMDIBuilderCreateReferenceType(LLVMDIBuilderRef Builder,unsigned int Tag,LLVMMetadataRef Type,unsigned int AddressSpace,unsigned int MemorySpace)
#
# Create C++11 nullptr type.
# \param Builder The DIBuilder.
cdef LLVMMetadataRef LLVMDIBuilderCreateNullPtrType(LLVMDIBuilderRef Builder)
#
# Create debugging information entry for a typedef.
# \param Builder The DIBuilder.
# \param Type Original type.
# \param Name Typedef name.
# \param File File where this type is defined.
# \param LineNo Line number.
# \param Scope The surrounding context for the typedef.
cdef LLVMMetadataRef LLVMDIBuilderCreateTypedef(LLVMDIBuilderRef Builder,LLVMMetadataRef Type,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNo,LLVMMetadataRef Scope,uint32_t AlignInBits)
#
# Create debugging information entry to establish inheritance relationship
# between two types.
# \param Builder The DIBuilder.
# \param Ty Original type.
# \param BaseTy Base type. Ty is inherits from base.
# \param BaseOffset Base offset.
# \param VBPtrOffset Virtual base pointer offset.
# \param Flags Flags to describe inheritance attribute, e.g. private
cdef LLVMMetadataRef LLVMDIBuilderCreateInheritance(LLVMDIBuilderRef Builder,LLVMMetadataRef Ty,LLVMMetadataRef BaseTy,uint64_t BaseOffset,uint32_t VBPtrOffset,LLVMDIFlags Flags)
#
# Create a permanent forward-declared type.
# \param Builder The DIBuilder.
# \param Tag A unique tag for this type.
# \param Name Type name.
# \param NameLen Length of type name.
# \param Scope Type scope.
# \param File File where this type is defined.
# \param Line Line number where this type is defined.
# \param RuntimeLang Indicates runtime version for languages like
# Objective-C.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param UniqueIdentifier A unique identifier for the type.
# \param UniqueIdentifierLen Length of the unique identifier.
cdef LLVMMetadataRef LLVMDIBuilderCreateForwardDecl(LLVMDIBuilderRef Builder,unsigned int Tag,const char * Name,size_t NameLen,LLVMMetadataRef Scope,LLVMMetadataRef File,unsigned int Line,unsigned int RuntimeLang,uint64_t SizeInBits,uint32_t AlignInBits,const char * UniqueIdentifier,size_t UniqueIdentifierLen)
#
# Create a temporary forward-declared type.
# \param Builder The DIBuilder.
# \param Tag A unique tag for this type.
# \param Name Type name.
# \param NameLen Length of type name.
# \param Scope Type scope.
# \param File File where this type is defined.
# \param Line Line number where this type is defined.
# \param RuntimeLang Indicates runtime version for languages like
# Objective-C.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param Flags Flags.
# \param UniqueIdentifier A unique identifier for the type.
# \param UniqueIdentifierLen Length of the unique identifier.
cdef LLVMMetadataRef LLVMDIBuilderCreateReplaceableCompositeType(LLVMDIBuilderRef Builder,unsigned int Tag,const char * Name,size_t NameLen,LLVMMetadataRef Scope,LLVMMetadataRef File,unsigned int Line,unsigned int RuntimeLang,uint64_t SizeInBits,uint32_t AlignInBits,LLVMDIFlags Flags,const char * UniqueIdentifier,size_t UniqueIdentifierLen)
#
# Create debugging information entry for a bit field member.
# \param Builder The DIBuilder.
# \param Scope Member scope.
# \param Name Member name.
# \param NameLen Length of member name.
# \param File File where this member is defined.
# \param LineNumber Line number.
# \param SizeInBits Member size.
# \param OffsetInBits Member offset.
# \param StorageOffsetInBits Member storage offset.
# \param Flags Flags to encode member attribute.
# \param Type Parent type.
cdef LLVMMetadataRef LLVMDIBuilderCreateBitFieldMemberType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,uint64_t SizeInBits,uint64_t OffsetInBits,uint64_t StorageOffsetInBits,LLVMDIFlags Flags,LLVMMetadataRef Type)
#
# Create debugging information entry for a class.
# \param Scope Scope in which this class is defined.
# \param Name Class name.
# \param NameLen The length of the C string passed to \c Name.
# \param File File where this member is defined.
# \param LineNumber Line number.
# \param SizeInBits Member size.
# \param AlignInBits Member alignment.
# \param OffsetInBits Member offset.
# \param Flags Flags to encode member attribute, e.g. private.
# \param DerivedFrom Debug info of the base class of this type.
# \param Elements Class members.
# \param NumElements Number of class elements.
# \param 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.
# \param TemplateParamsNode Template type parameters.
# \param UniqueIdentifier A unique identifier for the type.
# \param UniqueIdentifierLen Length of the unique identifier.
cdef LLVMMetadataRef LLVMDIBuilderCreateClassType(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNumber,uint64_t SizeInBits,uint32_t AlignInBits,uint64_t OffsetInBits,LLVMDIFlags Flags,LLVMMetadataRef DerivedFrom,LLVMMetadataRef * Elements,unsigned int NumElements,LLVMMetadataRef VTableHolder,LLVMMetadataRef TemplateParamsNode,const char * UniqueIdentifier,size_t UniqueIdentifierLen)
#
# Create a uniqued DIType* clone with FlagArtificial set.
# \param Builder The DIBuilder.
# \param Type The underlying type.
cdef LLVMMetadataRef LLVMDIBuilderCreateArtificialType(LLVMDIBuilderRef Builder,LLVMMetadataRef Type)
#
# Get the name of this DIType.
# \param DType The DIType.
# \param Length The length of the returned string.
#
# @see DIType::getName()
cdef const char * LLVMDITypeGetName(LLVMMetadataRef DType,size_t * Length)
#
# Get the size of this DIType in bits.
# \param DType The DIType.
#
# @see DIType::getSizeInBits()
cdef uint64_t LLVMDITypeGetSizeInBits(LLVMMetadataRef DType)
#
# Get the offset of this DIType in bits.
# \param DType The DIType.
#
# @see DIType::getOffsetInBits()
cdef uint64_t LLVMDITypeGetOffsetInBits(LLVMMetadataRef DType)
#
# Get the alignment of this DIType in bits.
# \param DType The DIType.
#
# @see DIType::getAlignInBits()
cdef uint32_t LLVMDITypeGetAlignInBits(LLVMMetadataRef DType)
#
# Get the source line where this DIType is declared.
# \param DType The DIType.
#
# @see DIType::getLine()
cdef unsigned int LLVMDITypeGetLine(LLVMMetadataRef DType)
#
# Get the flags associated with this DIType.
# \param DType The DIType.
#
# @see DIType::getFlags()
cdef LLVMDIFlags LLVMDITypeGetFlags(LLVMMetadataRef DType)
#
# Create a descriptor for a value range.
# \param Builder The DIBuilder.
# \param LowerBound Lower bound of the subrange, e.g. 0 for C, 1 for Fortran.
# \param Count Count of elements in the subrange.
cdef LLVMMetadataRef LLVMDIBuilderGetOrCreateSubrange(LLVMDIBuilderRef Builder,int64_t LowerBound,int64_t Count)
#
# Create an array of DI Nodes.
# \param Builder The DIBuilder.
# \param Data The DI Node elements.
# \param NumElements Number of DI Node elements.
cdef LLVMMetadataRef LLVMDIBuilderGetOrCreateArray(LLVMDIBuilderRef Builder,LLVMMetadataRef * Data,size_t NumElements)
#
# Create a new descriptor for the specified variable which has a complex
# address expression for its address.
# \param Builder The DIBuilder.
# \param Addr An array of complex address operations.
# \param Length Length of the address operation array.
cdef LLVMMetadataRef LLVMDIBuilderCreateExpression(LLVMDIBuilderRef Builder,uint64_t * Addr,size_t Length)
#
# Create a new descriptor for the specified variable that does not have an
# address, but does have a constant value.
# \param Builder The DIBuilder.
# \param Value The constant value.
cdef LLVMMetadataRef LLVMDIBuilderCreateConstantValueExpression(LLVMDIBuilderRef Builder,uint64_t Value)
#
# Create a new descriptor for the specified variable.
# \param Scope Variable scope.
# \param Name Name of the variable.
# \param NameLen The length of the C string passed to \c Name.
# \param Linkage Mangled name of the variable.
# \param LinkLen The length of the C string passed to \c Linkage.
# \param File File where this variable is defined.
# \param LineNo Line number.
# \param Ty Variable Type.
# \param LocalToUnit Boolean flag indicate whether this variable is
# externally visible or not.
# \param Expr The location of the global relative to the attached
# GlobalVariable.
# \param Decl Reference to the corresponding declaration.
# variables.
# \param AlignInBits Variable alignment(or 0 if no alignment attr was
# specified)
cdef LLVMMetadataRef LLVMDIBuilderCreateGlobalVariableExpression(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,const char * Linkage,size_t LinkLen,LLVMMetadataRef File,unsigned int LineNo,LLVMMetadataRef Ty,int LocalToUnit,LLVMMetadataRef Expr,LLVMMetadataRef Decl,unsigned int MS,uint32_t AlignInBits)
#
# Get the dwarf::Tag of a DINode
cdef uint16_t LLVMGetDINodeTag(LLVMMetadataRef MD)
#
# Retrieves the \c DIVariable associated with this global variable expression.
# \param GVE The global variable expression.
#
# @see llvm::DIGlobalVariableExpression::getVariable()
cdef LLVMMetadataRef LLVMDIGlobalVariableExpressionGetVariable(LLVMMetadataRef GVE)
#
# Retrieves the \c DIExpression associated with this global variable expression.
# \param GVE The global variable expression.
#
# @see llvm::DIGlobalVariableExpression::getExpression()
cdef LLVMMetadataRef LLVMDIGlobalVariableExpressionGetExpression(LLVMMetadataRef GVE)
#
# Get the metadata of the file associated with a given variable.
# \param Var The variable object.
#
# @see DIVariable::getFile()
cdef LLVMMetadataRef LLVMDIVariableGetFile(LLVMMetadataRef Var)
#
# Get the metadata of the scope associated with a given variable.
# \param Var The variable object.
#
# @see DIVariable::getScope()
cdef LLVMMetadataRef LLVMDIVariableGetScope(LLVMMetadataRef Var)
#
# Get the source line where this \c DIVariable is declared.
# \param Var The DIVariable.
#
# @see DIVariable::getLine()
cdef unsigned int LLVMDIVariableGetLine(LLVMMetadataRef Var)
#
# Create a new temporary \c MDNode. Suitable for use in constructing cyclic
# \c MDNode structures. A temporary \c MDNode is not uniqued, may be RAUW'd,
# and must be manually deleted with \c LLVMDisposeTemporaryMDNode.
# \param Ctx The context in which to construct the temporary node.
# \param Data The metadata elements.
# \param NumElements Number of metadata elements.
cdef LLVMMetadataRef LLVMTemporaryMDNode(LLVMContextRef Ctx,LLVMMetadataRef * Data,size_t NumElements)
#
# Deallocate a temporary node.
#
# Calls \c replaceAllUsesWith(nullptr) before deleting, so any remaining
# references will be reset.
# \param TempNode The temporary metadata node.
cdef void LLVMDisposeTemporaryMDNode(LLVMMetadataRef TempNode)
#
# Replace all uses of temporary metadata.
# \param TempTargetMetadata The temporary metadata node.
# \param Replacement The replacement metadata node.
cdef void LLVMMetadataReplaceAllUsesWith(LLVMMetadataRef TempTargetMetadata,LLVMMetadataRef Replacement)
#
# Create a new descriptor for the specified global variable that is temporary
# and meant to be RAUWed.
# \param Scope Variable scope.
# \param Name Name of the variable.
# \param NameLen The length of the C string passed to \c Name.
# \param Linkage Mangled name of the variable.
# \param LnkLen The length of the C string passed to \c Linkage.
# \param File File where this variable is defined.
# \param LineNo Line number.
# \param Ty Variable Type.
# \param LocalToUnit Boolean flag indicate whether this variable is
# externally visible or not.
# \param Decl Reference to the corresponding declaration.
# \param AlignInBits Variable alignment(or 0 if no alignment attr was
# specified)
cdef LLVMMetadataRef LLVMDIBuilderCreateTempGlobalVariableFwdDecl(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,const char * Linkage,size_t LnkLen,LLVMMetadataRef File,unsigned int LineNo,LLVMMetadataRef Ty,int LocalToUnit,LLVMMetadataRef Decl,uint32_t AlignInBits)
#
# Only use in "new debug format" (LLVMIsNewDbgInfoFormat() is true).
# See https://llvm.org/docs/RemoveDIsDebugInfo.html#c-api-changes
#
# The debug format can be switched later after inserting the records using
# LLVMSetIsNewDbgInfoFormat, if needed for legacy or transitionary reasons.
#
# Insert a Declare DbgRecord before the given instruction.
# \param Builder The DIBuilder.
# \param Storage The storage of the variable to declare.
# \param VarInfo The variable's debug info descriptor.
# \param Expr A complex location expression for the variable.
# \param DebugLoc Debug info location.
# \param Instr Instruction acting as a location for the new record.
cdef LLVMDbgRecordRef LLVMDIBuilderInsertDeclareRecordBefore(LLVMDIBuilderRef Builder,LLVMValueRef Storage,LLVMMetadataRef VarInfo,LLVMMetadataRef Expr,LLVMMetadataRef DebugLoc,LLVMValueRef Instr)
#
# Only use in "new debug format" (LLVMIsNewDbgInfoFormat() is true).
# See https://llvm.org/docs/RemoveDIsDebugInfo.html#c-api-changes
#
# The debug format can be switched later after inserting the records using
# LLVMSetIsNewDbgInfoFormat, if needed for legacy or transitionary reasons.
#
# Insert a Declare DbgRecord at the end of the given basic block. If the basic
# block has a terminator instruction, the record is inserted before that
# terminator instruction.
# \param Builder The DIBuilder.
# \param Storage The storage of the variable to declare.
# \param VarInfo The variable's debug info descriptor.
# \param Expr A complex location expression for the variable.
# \param DebugLoc Debug info location.
# \param Block Basic block acting as a location for the new record.
cdef LLVMDbgRecordRef LLVMDIBuilderInsertDeclareRecordAtEnd(LLVMDIBuilderRef Builder,LLVMValueRef Storage,LLVMMetadataRef VarInfo,LLVMMetadataRef Expr,LLVMMetadataRef DebugLoc,LLVMBasicBlockRef Block)
#
# Only use in "new debug format" (LLVMIsNewDbgInfoFormat() is true).
# See https://llvm.org/docs/RemoveDIsDebugInfo.html#c-api-changes
#
# The debug format can be switched later after inserting the records using
# LLVMSetIsNewDbgInfoFormat, if needed for legacy or transitionary reasons.
#
# Insert a new debug record before the given instruction.
# \param Builder The DIBuilder.
# \param Val The value of the variable.
# \param VarInfo The variable's debug info descriptor.
# \param Expr A complex location expression for the variable.
# \param DebugLoc Debug info location.
# \param Instr Instruction acting as a location for the new record.
cdef LLVMDbgRecordRef LLVMDIBuilderInsertDbgValueRecordBefore(LLVMDIBuilderRef Builder,LLVMValueRef Val,LLVMMetadataRef VarInfo,LLVMMetadataRef Expr,LLVMMetadataRef DebugLoc,LLVMValueRef Instr)
#
# Only use in "new debug format" (LLVMIsNewDbgInfoFormat() is true).
# See https://llvm.org/docs/RemoveDIsDebugInfo.html#c-api-changes
#
# The debug format can be switched later after inserting the records using
# LLVMSetIsNewDbgInfoFormat, if needed for legacy or transitionary reasons.
#
# Insert a new debug record at the end of the given basic block. If the
# basic block has a terminator instruction, the record is inserted before
# that terminator instruction.
# \param Builder The DIBuilder.
# \param Val The value of the variable.
# \param VarInfo The variable's debug info descriptor.
# \param Expr A complex location expression for the variable.
# \param DebugLoc Debug info location.
# \param Block Basic block acting as a location for the new record.
cdef LLVMDbgRecordRef LLVMDIBuilderInsertDbgValueRecordAtEnd(LLVMDIBuilderRef Builder,LLVMValueRef Val,LLVMMetadataRef VarInfo,LLVMMetadataRef Expr,LLVMMetadataRef DebugLoc,LLVMBasicBlockRef Block)
#
# Create a new descriptor for a local auto variable.
# \param Builder The DIBuilder.
# \param Scope The local scope the variable is declared in.
# \param Name Variable name.
# \param NameLen Length of variable name.
# \param File File where this variable is defined.
# \param LineNo Line number.
# \param Ty Metadata describing the type of the variable.
# \param AlwaysPreserve If true, this descriptor will survive optimizations.
# \param Flags Flags.
# \param AlignInBits Variable alignment.
cdef LLVMMetadataRef LLVMDIBuilderCreateAutoVariable(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNo,LLVMMetadataRef Ty,int AlwaysPreserve,LLVMDIFlags Flags,unsigned int MS,uint32_t AlignInBits)
#
# Create a new descriptor for a function parameter variable.
# \param Builder The DIBuilder.
# \param Scope The local scope the variable is declared in.
# \param Name Variable name.
# \param NameLen Length of variable name.
# \param ArgNo Unique argument number for this variable; starts at 1.
# \param File File where this variable is defined.
# \param LineNo Line number.
# \param Ty Metadata describing the type of the variable.
# \param AlwaysPreserve If true, this descriptor will survive optimizations.
# \param Flags Flags.
cdef LLVMMetadataRef LLVMDIBuilderCreateParameterVariable(LLVMDIBuilderRef Builder,LLVMMetadataRef Scope,const char * Name,size_t NameLen,unsigned int ArgNo,LLVMMetadataRef File,unsigned int LineNo,LLVMMetadataRef Ty,int AlwaysPreserve,LLVMDIFlags Flags)
#
# Get the metadata of the subprogram attached to a function.
#
# @see llvm::Function::getSubprogram()
cdef LLVMMetadataRef LLVMGetSubprogram(LLVMValueRef Func)
#
# Set the subprogram attached to a function.
#
# @see llvm::Function::setSubprogram()
cdef void LLVMSetSubprogram(LLVMValueRef Func,LLVMMetadataRef SP)
#
# Get the line associated with a given subprogram.
# \param Subprogram The subprogram object.
#
# @see DISubprogram::getLine()
cdef unsigned int LLVMDISubprogramGetLine(LLVMMetadataRef Subprogram)
#
# Replace the subprogram subroutine type.
# \param Subprogram The subprogram object.
# \param SubroutineType The new subroutine type.
#
# @see DISubprogram::replaceType()
cdef void LLVMDISubprogramReplaceType(LLVMMetadataRef Subprogram,LLVMMetadataRef SubroutineType)
#
# Get the debug location for the given instruction.
#
# @see llvm::Instruction::getDebugLoc()
cdef LLVMMetadataRef LLVMInstructionGetDebugLoc(LLVMValueRef Inst)
#
# Set the debug location for the given instruction.
#
# To clear the location metadata of the given instruction, pass NULL to \p Loc.
#
# @see llvm::Instruction::setDebugLoc()
cdef void LLVMInstructionSetDebugLoc(LLVMValueRef Inst,LLVMMetadataRef Loc)
#
# Create a new descriptor for a label
#
# \param Builder The DIBuilder.
# \param Scope The scope to create the label in.
# \param Name Variable name.
# \param NameLen Length of variable name.
# \param File The file to create the label in.
# \param LineNo Line Number.
# \param AlwaysPreserve Preserve the label regardless of optimization.
#
# @see llvm::DIBuilder::createLabel()
cdef LLVMMetadataRef LLVMDIBuilderCreateLabel(LLVMDIBuilderRef Builder,LLVMMetadataRef Context,const char * Name,size_t NameLen,LLVMMetadataRef File,unsigned int LineNo,int AlwaysPreserve)
#
# Insert a new llvm.dbg.label intrinsic call
#
# \param Builder The DIBuilder.
# \param LabelInfo The Label's debug info descriptor
# \param Location The debug info location
# \param InsertBefore Location for the new intrinsic.
#
# @see llvm::DIBuilder::insertLabel()
cdef LLVMDbgRecordRef LLVMDIBuilderInsertLabelBefore(LLVMDIBuilderRef Builder,LLVMMetadataRef LabelInfo,LLVMMetadataRef Location,LLVMValueRef InsertBefore)
#
# Insert a new llvm.dbg.label intrinsic call
#
# \param Builder The DIBuilder.
# \param LabelInfo The Label's debug info descriptor
# \param Location The debug info location
# \param InsertAtEnd Location for the new intrinsic.
#
# @see llvm::DIBuilder::insertLabel()
cdef LLVMDbgRecordRef LLVMDIBuilderInsertLabelAtEnd(LLVMDIBuilderRef Builder,LLVMMetadataRef LabelInfo,LLVMMetadataRef Location,LLVMBasicBlockRef InsertAtEnd)
#
# Obtain the enumerated type of a Metadata instance.
#
# @see llvm::Metadata::getMetadataID()
cdef unsigned int LLVMGetMetadataKind(LLVMMetadataRef Metadata)
cdef bint __debuginfo_has_symbol(const char* name) noexcept nogil