[#llvm-DIBasicType] = xref:llvm.adoc[llvm]::DIBasicType :relfileprefix: ../ :mrdocs: Basic type, like 'int' or 'float'. == Synopsis Declared in `<llvm/IR/DebugInfoMetadata.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- class DIBasicType : public xref:llvm/DIType.adoc[DIType] ---- == Description TODO: Split out DW_TAG_unspecified_type. TODO: Drop unused accessors. == Base Classes [cols="1,4"] |=== | Name| Description | `xref:llvm/DIType.adoc[DIType]` | Base class for types. |=== == Type Aliases [cols="1,4"] |=== | Name| Description | xref:llvm/MDNode/op_iterator.adoc[`op_iterator`] | Iterator over this node's operands. | xref:llvm/MDNode/op_range.adoc[`op_range`] | Range of this node's operands. |=== == Enums [cols="1,4"] |=== | Name| Description | xref:llvm/DINode/DIFlags.adoc[`DIFlags`] | Debug info flags. | xref:llvm/Metadata/MetadataKind.adoc[`MetadataKind`] | RTTI identifiers for concrete metadata subclasses. | xref:llvm/DIBasicType/Signedness.adoc[`Signedness`] | Whether a basic type is signed or unsigned. |=== == Member Functions [cols="1,4"] |=== | Name| Description | xref:llvm/MDNode/operator_assign.adoc[`operator=`] [.small]#[deleted]# | Copy assignment is deleted; MDNode is non‐copyable. | xref:llvm/DIBasicType/clone.adoc[`clone`] | Return a (temporary) clone of this. | xref:llvm/DIType/cloneWithFlags.adoc[`cloneWithFlags`] | Returns a new temporary DIType with updated Flags | xref:llvm/Metadata/dump-08.adoc[`dump`] | `dump` overloads | xref:llvm/MDNode/dumpTree-02.adoc[`dumpTree`] | `dumpTree` overloads | xref:llvm/DIType/getAlignInBits.adoc[`getAlignInBits`] | Return the align in bits. | xref:llvm/DIType/getAlignInBytes.adoc[`getAlignInBytes`] | Return the align in bytes. | xref:llvm/MDNode/getContext.adoc[`getContext`] | Return the LLVM context that owns this node. | xref:llvm/DIBasicType/getDataSizeInBits.adoc[`getDataSizeInBits`] | Return the data size in bits. | xref:llvm/DIScope/getDirectory.adoc[`getDirectory`] | Return the directory. | xref:llvm/DIBasicType/getEncoding.adoc[`getEncoding`] | Return the encoding. | xref:llvm/DIType/getExportSymbols.adoc[`getExportSymbols`] | Return the export symbols. | xref:llvm/DIScope/getFile.adoc[`getFile`] | Return the file. | xref:llvm/DIScope/getFilename.adoc[`getFilename`] | Return the filename. | xref:llvm/DIType/getFlags.adoc[`getFlags`] | Return the flags. | xref:llvm/DIType/getLine.adoc[`getLine`] | Return the line. | xref:llvm/Metadata/getMetadataID.adoc[`getMetadataID`] | Return the metadata kind ID for this node. | xref:llvm/DIType/getName.adoc[`getName`] | Return the name. | xref:llvm/DIType/getNumExtraInhabitants.adoc[`getNumExtraInhabitants`] | Return the num extra inhabitants. | xref:llvm/MDNode/getNumOperands.adoc[`getNumOperands`] | Return number of MDNode operands. | xref:llvm/MDNode/getNumTemporaryUses.adoc[`getNumTemporaryUses`] | Return the number of uses of this temporary metadata node. | xref:llvm/DIType/getOffsetInBits.adoc[`getOffsetInBits`] | Return the offset in bits. | xref:llvm/MDNode/getOperand.adoc[`getOperand`] | Return the operand at index `I.` | xref:llvm/DIScope/getRawFile.adoc[`getRawFile`] | Return the raw underlying file. | xref:llvm/DIType/getRawName.adoc[`getRawName`] | Return the raw name operand. | xref:llvm/DIType/getRawOffsetInBits.adoc[`getRawOffsetInBits`] | Return the raw offset in bits operand. | xref:llvm/DIType/getRawScope.adoc[`getRawScope`] | Return the raw scope operand. | xref:llvm/DIType/getRawSizeInBits.adoc[`getRawSizeInBits`] | Return the raw size in bits operand. | xref:llvm/DIType/getScope.adoc[`getScope`] | Return the scope. | xref:llvm/DIBasicType/getSignedness.adoc[`getSignedness`] | Return the signedness of this type, or std::nullopt if this type is neither signed nor unsigned. | xref:llvm/DIType/getSizeInBits.adoc[`getSizeInBits`] | Return the size in bits. | xref:llvm/DIScope/getSource.adoc[`getSource`] | Return the source. | xref:llvm/DINode/getTag.adoc[`getTag`] | Return the tag. | xref:llvm/MDNode/isAlwaysReplaceable.adoc[`isAlwaysReplaceable`] | Return true if this node kind is always RAUW‐replaceable (e.g. DIAssignID). | xref:llvm/DIType/isAppleBlockExtension.adoc[`isAppleBlockExtension`] | Return true if this is apple block extension. | xref:llvm/DIType/isArtificial.adoc[`isArtificial`] | Return true if this is artificial. | xref:llvm/DIType/isBigEndian.adoc[`isBigEndian`] | Return true if this is big endian. | xref:llvm/DIType/isBitField.adoc[`isBitField`] | Return true if this is bit field. | xref:llvm/MDNode/isDistinct.adoc[`isDistinct`] | Return true if this node is distinct (not uniqued). | xref:llvm/DIType/isForwardDecl.adoc[`isForwardDecl`] | Return true if this is forward decl. | xref:llvm/DIType/isLValueReference.adoc[`isLValueReference`] | Return true if this is l value reference. | xref:llvm/DIType/isLittleEndian.adoc[`isLittleEndian`] | Return true if this is little endian. | xref:llvm/DIType/isObjcClassComplete.adoc[`isObjcClassComplete`] | Return true if this is objc class complete. | xref:llvm/DIType/isObjectPointer.adoc[`isObjectPointer`] | Return true if this is object pointer. | xref:llvm/DIType/isPrivate.adoc[`isPrivate`] | Return true if this is private. | xref:llvm/DIType/isProtected.adoc[`isProtected`] | Return true if this is protected. | xref:llvm/DIType/isPublic.adoc[`isPublic`] | Return true if this is public. | xref:llvm/DIType/isRValueReference.adoc[`isRValueReference`] | Return true if this is r value reference. | xref:llvm/MDNode/isReplaceable.adoc[`isReplaceable`] | Return true if this node supports RAUW replacement. | xref:llvm/MDNode/isResolved.adoc[`isResolved`] | Check if node is fully resolved. | xref:llvm/DIType/isStaticMember.adoc[`isStaticMember`] | Return true if this is static member. | xref:llvm/MDNode/isTBAAVtableAccess.adoc[`isTBAAVtableAccess`] | Check whether MDNode is a vtable access. | xref:llvm/MDNode/isTemporary.adoc[`isTemporary`] | Return true if this is a temporary (forward‐declaration) metadata node. | xref:llvm/DIType/isTypePassByReference.adoc[`isTypePassByReference`] | Return true if this is type pass by reference. | xref:llvm/DIType/isTypePassByValue.adoc[`isTypePassByValue`] | Return true if this is type pass by value. | xref:llvm/MDNode/isUniqued.adoc[`isUniqued`] | Return true if this node is uniqued in the context. | xref:llvm/DIType/isVector.adoc[`isVector`] | Return true if this is vector. | xref:llvm/DIType/isVirtual.adoc[`isVirtual`] | Return true if this is virtual. | xref:llvm/MDNode/op_begin.adoc[`op_begin`] | Return an iterator to the first operand. | xref:llvm/MDNode/op_end.adoc[`op_end`] | Return an iterator past the last operand. | xref:llvm/MDNode/operands.adoc[`operands`] | Return this node's operands as an array reference. | xref:llvm/MDNode/operator_new-09.adoc[`operator new`] [.small]#[deleted]# | Ordinary allocation is deleted; use the custom MDNode allocators. | xref:llvm/Metadata/print-0c.adoc[`print`] | `print` overloads | xref:llvm/Metadata/printAsOperand-09e.adoc[`printAsOperand`] | `printAsOperand` overloads | xref:llvm/MDNode/printTree-08.adoc[`printTree`] | `printTree` overloads | xref:llvm/MDNode/replaceAllUsesWith.adoc[`replaceAllUsesWith`] | RAUW a temporary. | xref:llvm/MDNode/replaceOperandWith.adoc[`replaceOperandWith`] | Replace a specific operand. | xref:llvm/MDNode/resolve.adoc[`resolve`] | Resolve a unique, unresolved node. | xref:llvm/MDNode/resolveCycles.adoc[`resolveCycles`] | Resolve cycles. |=== == Static Member Functions [cols="1,4"] |=== | Name| Description | xref:llvm/DIBasicType/classof.adoc[`classof`] | Check whether `MD` is this kind of metadata. | xref:llvm/MDNode/concatenate.adoc[`concatenate`] | Methods for metadata merging. Concatenate metadata nodes `A` and `B.` | xref:llvm/MDNode/deleteTemporary.adoc[`deleteTemporary`] | Deallocate a node created by getTemporary. | xref:llvm/MDNode/fromCaptureComponents.adoc[`fromCaptureComponents`] | Convert CaptureComponents to !captures metadata. The return value may be nullptr. | xref:llvm/DIBasicType/get-05.adoc[`get`] | `get` overloads | xref:llvm/DIBasicType/getDistinct-01c.adoc[`getDistinct`] | `getDistinct` overloads | xref:llvm/DINode/getFlag.adoc[`getFlag`] | Return the flag. | xref:llvm/DINode/getFlagString.adoc[`getFlagString`] | Return the flag string. | xref:llvm/DIBasicType/getIfExists-0f.adoc[`getIfExists`] | `getIfExists` overloads | xref:llvm/MDNode/getMergedAllocTokenMetadata.adoc[`getMergedAllocTokenMetadata`] | Merge alloc‐token metadata from two instructions. | xref:llvm/MDNode/getMergedCalleeTypeMetadata.adoc[`getMergedCalleeTypeMetadata`] | Merge callee‐type metadata from two instructions. | xref:llvm/MDNode/getMergedCallsiteMetadata.adoc[`getMergedCallsiteMetadata`] | Merge callsite metadata from two instructions. | xref:llvm/MDNode/getMergedMemProfMetadata.adoc[`getMergedMemProfMetadata`] | Merge memprof metadata from two instructions. | xref:llvm/MDNode/getMergedProfMetadata.adoc[`getMergedProfMetadata`] | Merge !prof metadata from two instructions. Currently only implemented with direct callsites with branch weights. | xref:llvm/MDNode/getMostGenericAliasScope.adoc[`getMostGenericAliasScope`] | Merge alias‐scope metadata, keeping scopes present in both. | xref:llvm/MDNode/getMostGenericAlignmentOrDereferenceable.adoc[`getMostGenericAlignmentOrDereferenceable`] | Merge align/dereferenceable metadata, returning the most generic bound. | xref:llvm/MDNode/getMostGenericFPMath.adoc[`getMostGenericFPMath`] | Merge FP‐math metadata, returning the most generic accuracy. | xref:llvm/MDNode/getMostGenericNoFPClass.adoc[`getMostGenericNoFPClass`] | Merge `!nofpclass` metadata by intersecting the allowed FP classes. | xref:llvm/MDNode/getMostGenericNoaliasAddrspace.adoc[`getMostGenericNoaliasAddrspace`] | Merge noalias address‐space metadata, returning the most generic set. | xref:llvm/MDNode/getMostGenericRange.adoc[`getMostGenericRange`] | Merge !range metadata by taking the union of the integer intervals. | xref:llvm/MDNode/getMostGenericTBAA.adoc[`getMostGenericTBAA`] | Merge TBAA metadata, returning the most generic common tag. | xref:llvm/DIBasicType/getTemporary-0a3.adoc[`getTemporary`] | `getTemporary` overloads | xref:llvm/MDNode/intersect.adoc[`intersect`] | Intersect metadata nodes `A` and `B.` | xref:llvm/MDNode/replaceWithDistinct.adoc[`replaceWithDistinct`] | Replace a temporary node with a distinct one. | xref:llvm/MDNode/replaceWithPermanent.adoc[`replaceWithPermanent`] | Replace a temporary node with a permanent one. | xref:llvm/MDNode/replaceWithUniqued.adoc[`replaceWithUniqued`] | Replace a temporary node with a uniqued one. | xref:llvm/DINode/splitFlags.adoc[`splitFlags`] | Split up a flags bitfield. | xref:llvm/MDNode/toCaptureComponents.adoc[`toCaptureComponents`] | Convert !captures metadata to CaptureComponents. MD may be nullptr. |=== == Static Data Members [cols="1,4"] |=== | Name| Description | xref:llvm/Metadata/PoisonGeneratingIDs.adoc[`PoisonGeneratingIDs`] | Metadata IDs that may generate poison. |=== == Protected Type Aliases [cols="1,4"] |=== | Name| Description | xref:llvm/MDNode/mutable_op_range.adoc[`mutable_op_range`] | Range type over mutable `MDOperand` elements. |=== == Protected Enums [cols="1,4"] |=== | Name| Description | xref:llvm/Metadata/StorageType.adoc[`StorageType`] | Active type of storage. |=== == Protected Member Functions [cols="1,4"] |=== | Name| Description | xref:llvm/DIBasicType/2constructor-04.adoc[`DIBasicType`] [.small]#[constructor]# | Constructors | xref:llvm/DIBasicType/2destructor.adoc[`~DIBasicType`] [.small]#[destructor]# | Destroy this DIBasicType. | xref:llvm/DIBasicType/cloneImpl.adoc[`cloneImpl`] | Clone this node into a temporary. | xref:llvm/MDNode/dropAllReferences.adoc[`dropAllReferences`] | Drop all references held by this metadata node. | xref:llvm/MDNode/getNumUnresolved.adoc[`getNumUnresolved`] | Return the number of unresolved operands in this node. | xref:llvm/DINode/getOperandAs.adoc[`getOperandAs`] | Return the operand as. | xref:llvm/DINode/getStringOperand.adoc[`getStringOperand`] | Return the string operand. | xref:llvm/Metadata/handleChangedOperand.adoc[`handleChangedOperand`] | Default handling of a changed operand, which asserts. | xref:llvm/DIType/init.adoc[`init`] | Initialize common DIType fields. | xref:llvm/MDNode/mutable_begin.adoc[`mutable_begin`] | Return an iterator to the first mutable operand. | xref:llvm/MDNode/mutable_end.adoc[`mutable_end`] | Return an iterator past the last mutable operand. | xref:llvm/MDNode/mutable_operands.adoc[`mutable_operands`] | Return a mutable range over this node's operands. | xref:llvm/DIType/mutate.adoc[`mutate`] | Change fields in place. | xref:llvm/MDNode/operator_del-03b.adoc[`operator delete`] | Delete operators | xref:llvm/MDNode/operator_new-01.adoc[`operator new`] | Allocate an `MDNode` with `NumOps` operand slots and `Storage` kind. | xref:llvm/MDNode/resize.adoc[`resize`] | Resize the node to hold _NumOps_ operands. | xref:llvm/MDNode/setNumUnresolved.adoc[`setNumUnresolved`] | Set the number of unresolved operands in this node. | xref:llvm/MDNode/setOperand.adoc[`setOperand`] | Set an operand. | xref:llvm/DINode/setTag.adoc[`setTag`] | Allow subclasses to mutate the tag. | xref:llvm/MDNode/storeDistinctInContext.adoc[`storeDistinctInContext`] | Register this node as a distinct MDNode owned by the LLVMContext. |=== == Protected Static Member Functions [cols="1,4"] |=== | Name| Description | xref:llvm/DINode/getCanonicalMDString.adoc[`getCanonicalMDString`] | Return the canonical md string. | xref:llvm/DIBasicType/getImpl-0c.adoc[`getImpl`] | Get or create a node with the given operands. | xref:llvm/MDNode/storeImpl-00.adoc[`storeImpl`] | `storeImpl` overloads |=== == Protected Data Members [cols="1,4"] |=== | Name| Description | xref:llvm/Metadata/Storage.adoc[`Storage`] | Storage flag for non‐uniqued, otherwise unowned, metadata. | xref:llvm/Metadata/SubclassData1.adoc[`SubclassData1`] | One bit of subclass‐specific state packed into the metadata header. | xref:llvm/Metadata/SubclassData16.adoc[`SubclassData16`] | Sixteen bits of subclass‐specific state packed into the metadata header. | xref:llvm/Metadata/SubclassData32.adoc[`SubclassData32`] | Thirty‐two bits of subclass‐specific state packed into the metadata header. |=== == Protected Static Data Members [cols="1,4"] |=== | Name| Description | xref:llvm/DIType/N_OPERANDS.adoc[`N_OPERANDS`] | Number of fixed operands shared by all DIType subclasses. |=== == Friends [cols="1,4"] |=== | Name| Description | `xref:llvm/MDNode.adoc[llvm::MDNode]` | Metadata node. | `xref:llvm/LLVMContextImpl.adoc[llvm::LLVMContextImpl]` | Private implementation details of `LLVMContext.` |=== == Non-Member Functions [cols="1,4"] |=== | Name| Description | xref:llvm/GetUnrollMetadata.adoc[`GetUnrollMetadata`] | Return the named unroll hint metadata operand from loop id `LoopID.` | xref:llvm/MapMetadata-00.adoc[`MapMetadata`] | Lookup or compute a mapping for a piece of metadata. | xref:llvm/MapMetadata-0c.adoc[`MapMetadata`] | Version of MapMetadata with type safety for MDNode. | xref:llvm/UpgradeTBAANode.adoc[`UpgradeTBAANode`] | Upgrade a scalar TBAA tag to the struct‐path aware TBAA format. | xref:llvm/computeKnownBitsFromRangeMetadata.adoc[`computeKnownBitsFromRangeMetadata`] | Compute known bits from the range metadata. `KnownZero` the set of bits that are known to be zero `KnownOne` the set of bits that are known to be one | xref:llvm/extractBranchWeights-01.adoc[`extractBranchWeights`] | Extract branch weights from MD_prof metadata | xref:llvm/extractFromBranchWeightMD32.adoc[`extractFromBranchWeightMD32`] | Faster version of extractBranchWeights() that skips checks and must only be called with "branch_weights" metadata nodes. Supports uint32_t. | xref:llvm/extractFromBranchWeightMD64.adoc[`extractFromBranchWeightMD64`] | Faster version of extractBranchWeights() that skips checks and must only be called with "branch_weights" metadata nodes. Supports uint64_t. | xref:llvm/extractProfTotalWeight-0b.adoc[`extractProfTotalWeight`] | Retrieve the total of all weights from MD_prof data. | xref:llvm/findOptionMDForLoopID.adoc[`findOptionMDForLoopID`] | Find and return the loop attribute node for the attribute `Name` in `LoopID.` Return nullptr if there is no such attribute. | xref:llvm/getBranchWeightOffset.adoc[`getBranchWeightOffset`] | Return the offset to the first branch weight data | xref:llvm/getConstantRangeFromMetadata.adoc[`getConstantRangeFromMetadata`] | Parse out a conservative ConstantRange from !range metadata. | xref:llvm/getDISubprogram.adoc[`getDISubprogram`] | Find subprogram that is enclosing this scope. | xref:llvm/getNumBranchWeights.adoc[`getNumBranchWeights`] | Return the number of branch weights stored in `ProfileData` | xref:llvm/hasBranchWeightOrigin-08.adoc[`hasBranchWeightOrigin`] | Check if Branch Weight Metadata has an "expected" field from an llvm.expect* intrinsic | xref:llvm/isBranchWeightMD.adoc[`isBranchWeightMD`] | Checks if an MDNode contains Branch Weight Metadata | xref:llvm/isExplicitlyUnknownProfileMetadata.adoc[`isExplicitlyUnknownProfileMetadata`] | Check whether `MD` is explicitly‐unknown profile metadata. | xref:llvm/isValidAsAccessGroup.adoc[`isValidAsAccessGroup`] | Return whether an MDNode might represent an access group. | xref:llvm/isValueProfileMD.adoc[`isValueProfileMD`] | Checks if an MDNode contains value profiling Metadata | xref:llvm/makeFollowupLoopID.adoc[`makeFollowupLoopID`] | Create a new loop identifier for a loop created from a loop transformation. | xref:llvm/uniteAccessGroups.adoc[`uniteAccessGroups`] | Compute the union of two access‐group lists. | xref:llvm/upgradeInstructionLoopAttachment.adoc[`upgradeInstructionLoopAttachment`] | Upgrade the loop attachment metadata node. | xref:llvm/wrap-057.adoc[`wrap`] | Wrap a `Metadata` pointer as an opaque `LLVMMetadataRef.` | xref:llvm/memprof/getMIBAllocType.adoc[`memprof::getMIBAllocType`] | Returns the allocation type from an MIB metadata node. | xref:llvm/memprof/getMIBStackNode.adoc[`memprof::getMIBStackNode`] | Returns the stack node from an MIB metadata node. |=== == Derived Classes [cols="1,4"] |=== | Name| Description | xref:llvm/DIFixedPointType.adoc[`DIFixedPointType`] | Fixed‐point type. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#