[#llvm-MDTuple] = xref:llvm.adoc[llvm]::MDTuple :relfileprefix: ../ :mrdocs: Tuple of metadata. == Synopsis Declared in `<llvm/IR/Metadata.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- class MDTuple : public xref:llvm/MDNode.adoc[MDNode] ---- == Description This is the simple _MDNode_ arbitrary tuple. Nodes are uniqued by default based on their operands. == Base Classes [cols="1,4"] |=== | Name| Description | `xref:llvm/MDNode.adoc[MDNode]` | Metadata node. |=== == 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/Metadata/MetadataKind.adoc[`MetadataKind`] | RTTI identifiers for concrete metadata subclasses. |=== == 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/MDTuple/clone.adoc[`clone`] | Return a (temporary) clone of this. | xref:llvm/Metadata/dump-08.adoc[`dump`] | `dump` overloads | xref:llvm/MDNode/dumpTree-02.adoc[`dumpTree`] | `dumpTree` overloads | xref:llvm/MDTuple/filter.adoc[`filter`] | Filter out tuple elements that do not satisfy predicate. Return this if no elements should be filtered out (without re‐uniquing). | xref:llvm/MDNode/getContext.adoc[`getContext`] | Return the LLVM context that owns this node. | xref:llvm/MDTuple/getHash.adoc[`getHash`] | Get the hash, if any. | xref:llvm/Metadata/getMetadataID.adoc[`getMetadataID`] | Return the metadata kind ID for this node. | 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/MDNode/getOperand.adoc[`getOperand`] | Return the operand at index `I.` | xref:llvm/MDNode/isAlwaysReplaceable.adoc[`isAlwaysReplaceable`] | Return true if this node kind is always RAUW‐replaceable (e.g. DIAssignID). | xref:llvm/MDNode/isDistinct.adoc[`isDistinct`] | Return true if this node is distinct (not uniqued). | 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/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/MDNode/isUniqued.adoc[`isUniqued`] | Return true if this node is uniqued in the context. | 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/MDTuple/pop_back.adoc[`pop_back`] | Shrink the operands by 1. | 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/MDTuple/push_back.adoc[`push_back`] | Append an element to the tuple. This will resize the node. | 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/MDTuple/classof.adoc[`classof`] | Methods for support type inquiry through isa, cast, and dyn_cast. | 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/MDTuple/get.adoc[`get`] | Create or return a uniqued tuple of the given metadata operands. | xref:llvm/MDTuple/getDistinct.adoc[`getDistinct`] | Return a distinct node. | xref:llvm/MDTuple/getIfExists.adoc[`getIfExists`] | Return an existing uniqued tuple for `MDs,` or null if none. | 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/MDTuple/getTemporary.adoc[`getTemporary`] | Return a temporary node. | 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/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/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/Metadata/handleChangedOperand.adoc[`handleChangedOperand`] | Default handling of a changed operand, which asserts. | 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/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/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/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. |=== == 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. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#