LLVM
8.0.1
|
#include "llvm/IR/Metadata.h"
Classes | |
struct | HasCachedHash |
Public Types | |
using | op_iterator = const MDOperand * |
using | op_range = iterator_range< op_iterator > |
Public Types inherited from llvm::Metadata | |
enum | MetadataKind |
Static Public Member Functions | |
static MDTuple * | get (LLVMContext &Context, ArrayRef< Metadata *> MDs) |
static MDTuple * | getIfExists (LLVMContext &Context, ArrayRef< Metadata *> MDs) |
static MDTuple * | getDistinct (LLVMContext &Context, ArrayRef< Metadata *> MDs) |
static TempMDTuple | getTemporary (LLVMContext &Context, ArrayRef< Metadata *> MDs) |
static void | deleteTemporary (MDNode *N) |
Deallocate a node created by getTemporary. More... | |
template<class T > | |
static std::enable_if< std::is_base_of< MDNode, T >::value, T * >::type | replaceWithPermanent (std::unique_ptr< T, TempMDNodeDeleter > N) |
Replace a temporary node with a permanent one. More... | |
template<class T > | |
static std::enable_if< std::is_base_of< MDNode, T >::value, T * >::type | replaceWithUniqued (std::unique_ptr< T, TempMDNodeDeleter > N) |
Replace a temporary node with a uniqued one. More... | |
template<class T > | |
static std::enable_if< std::is_base_of< MDNode, T >::value, T * >::type | replaceWithDistinct (std::unique_ptr< T, TempMDNodeDeleter > N) |
Replace a temporary node with a distinct one. More... | |
static bool | classof (const Metadata *MD) |
Methods for support type inquiry through isa, cast, and dyn_cast: More... | |
static MDNode * | concatenate (MDNode *A, MDNode *B) |
Methods for metadata merging. More... | |
static MDNode * | intersect (MDNode *A, MDNode *B) |
static MDNode * | getMostGenericTBAA (MDNode *A, MDNode *B) |
static MDNode * | getMostGenericFPMath (MDNode *A, MDNode *B) |
static MDNode * | getMostGenericRange (MDNode *A, MDNode *B) |
static MDNode * | getMostGenericAliasScope (MDNode *A, MDNode *B) |
static MDNode * | getMostGenericAlignmentOrDereferenceable (MDNode *A, MDNode *B) |
Protected Types | |
using | mutable_op_range = iterator_range< MDOperand * > |
Protected Types inherited from llvm::Metadata | |
enum | StorageType { Uniqued, Distinct, Temporary } |
Active type of storage. More... | |
Protected Member Functions | |
MDNode (LLVMContext &Context, unsigned ID, StorageType Storage, ArrayRef< Metadata *> Ops1, ArrayRef< Metadata *> Ops2=None) | |
~MDNode ()=default | |
void * | operator new (size_t Size, unsigned NumOps) |
void | operator delete (void *Mem) |
void | operator delete (void *, unsigned) |
Required by std, but never called. More... | |
void | operator delete (void *, unsigned, bool) |
Required by std, but never called. More... | |
void | dropAllReferences () |
MDOperand * | mutable_begin () |
MDOperand * | mutable_end () |
mutable_op_range | mutable_operands () |
void | setOperand (unsigned I, Metadata *New) |
Set an operand. More... | |
void | storeDistinctInContext () |
Protected Member Functions inherited from llvm::Metadata | |
Metadata (unsigned ID, StorageType Storage) | |
~Metadata ()=default | |
void | handleChangedOperand (void *, Metadata *) |
Default handling of a changed operand, which asserts. More... | |
Static Protected Member Functions | |
template<class T , class StoreT > | |
static T * | storeImpl (T *N, StorageType Storage, StoreT &Store) |
template<class T > | |
static T * | storeImpl (T *N, StorageType Storage) |
Friends | |
class | ReplaceableMetadataImpl |
class | LLVMContextImpl |
Additional Inherited Members | |
Protected Attributes inherited from llvm::Metadata | |
unsigned char | Storage: 7 |
Storage flag for non-uniqued, otherwise unowned, metadata. More... | |
unsigned char | ImplicitCode: 1 |
unsigned short | SubclassData16 = 0 |
unsigned | SubclassData32 = 0 |
Metadata node.
Metadata nodes can be uniqued, like constants, or distinct. Temporary metadata nodes (with full support for RAUW) can be used to delay uniquing until forward references are known. The basic metadata node is an MDTuple.
There is limited support for RAUW at construction time. At construction time, if any operand is a temporary node (or an unresolved uniqued node, which indicates a transitive temporary operand), the node itself will be unresolved. As soon as all operands become resolved, it will drop RAUW support permanently.
If an unresolved node is part of a cycle, resolveCycles() needs to be called on some member of the cycle once all temporary nodes have been replaced.
Definition at line 864 of file Metadata.h.
|
protected |
Definition at line 896 of file Metadata.h.
using llvm::MDNode::op_iterator = const MDOperand * |
Definition at line 1056 of file Metadata.h.
Definition at line 1057 of file Metadata.h.
|
protected |
Definition at line 504 of file Metadata.cpp.
References isUniqued(), and setOperand().
|
protecteddefault |
Methods for support type inquiry through isa, cast, and dyn_cast:
Definition at line 1078 of file Metadata.h.
References A, B, llvm::Metadata::getMetadataID(), and intersect().
TempMDNode MDNode::clone | ( | ) | const |
Create a (temporary) clone of this.
Definition at line 522 of file Metadata.cpp.
References llvm::Metadata::getMetadataID(), and llvm_unreachable.
Referenced by llvm::DIType::clone(), cloneOrBuildODR(), and wrapConstantAsMetadata().
Methods for metadata merging.
Definition at line 896 of file Metadata.cpp.
References B, getContext(), getOrSelfReference(), op_begin(), and op_end().
Referenced by AddAliasScopeMetadata(), llvm::LoopVersioning::annotateInstWithNoAlias(), CloneAliasScopeMetadata(), getMostGenericAliasScope(), and PropagateParallelLoopAccessMetadata().
|
static |
Deallocate a node created by getTemporary.
Calls replaceAllUsesWith(nullptr)
before deleting, so any remaining references will be reset.
Definition at line 831 of file Metadata.cpp.
References assert(), isTemporary(), and replaceAllUsesWith().
Referenced by LLVMDisposeTemporaryMDNode().
|
protected |
Definition at line 690 of file Metadata.cpp.
References assert(), E, llvm::Metadata::getMetadataID(), getNumOperands(), getOperand(), llvm::ContextAndReplaceableUses::getReplaceableUses(), llvm::ContextAndReplaceableUses::hasReplaceableUses(), I, isResolved(), isUniqued(), llvm_unreachable, llvm::RISCVFenceField::O, op_begin(), llvm::Ref, llvm::ReplaceableMetadataImpl::replaceAllUsesWith(), resolve(), llvm::ReplaceableMetadataImpl::resolveAllUses(), setOperand(), storeDistinctInContext(), llvm::ContextAndReplaceableUses::takeReplaceableUses(), and llvm::Metadata::Uniqued.
Referenced by llvm::NamedMDNode::~NamedMDNode().
|
inlinestatic |
Definition at line 1166 of file Metadata.h.
References llvm::MDTuple::get().
Referenced by AddAliasScopeMetadata(), llvm::Module::addModuleFlag(), AddRuntimeUnrollDisableMetaData(), llvm::LoopVersioning::annotateInstWithNoAlias(), llvm::annotateValueSite(), llvm::DIExpression::append(), buildMUBUFOffsetLoadStore(), canonicalizeMetadataForValue(), CloneAliasScopeMetadata(), llvm::DILocation::cloneWithDiscriminator(), llvm::GlobalObject::copyMetadata(), llvm::copyRangeMetadata(), createAccessTag(), llvm::MDBuilder::createAliasScope(), llvm::MDBuilder::createAliasScopeDomain(), llvm::MDBuilder::createAnonymousAARoot(), llvm::DIBuilder::createArrayType(), llvm::DIBuilder::createBasicType(), llvm::DIBuilder::createBitFieldMemberType(), llvm::MDBuilder::createBranchWeights(), llvm::MDBuilder::createCallees(), llvm::DIBuilder::createClassType(), llvm::DIBuilder::createConstantValueExpression(), llvm::DIBuilder::createEnumerationType(), llvm::DIBuilder::createEnumerator(), llvm::DIBuilder::createExpression(), llvm::createFalkorMarkStridedAccessesPass(), llvm::DIBuilder::createFile(), llvm::DIBuilder::createForwardDecl(), llvm::MDBuilder::createFPMath(), llvm::DIExpression::createFragmentExpression(), llvm::DIBuilder::createFriend(), llvm::MDBuilder::createFunctionEntryCount(), llvm::MDBuilder::createFunctionSectionPrefix(), llvm::DIBuilder::createGlobalVariableExpression(), createImportedModule(), llvm::DIBuilder::createInheritance(), llvm::MDBuilder::createIrrLoopHeaderWeight(), llvm::DIBuilder::createLexicalBlockFile(), llvm::DIBuilder::createMacro(), llvm::DIBuilder::createMemberPointerType(), llvm::DIBuilder::createMemberType(), llvm::DIBuilder::createModule(), llvm::DIBuilder::createNameSpace(), llvm::createObjCARCOptPass(), llvm::DIBuilder::createObjCIVar(), llvm::DIBuilder::createObjCProperty(), llvm::createPGOFuncNameMetadata(), llvm::DIBuilder::createPointerType(), llvm::DIBuilder::createQualifiedType(), llvm::MDBuilder::createRange(), llvm::DIBuilder::createReferenceType(), llvm::createSIAddIMGInitPass(), llvm::DIBuilder::createStaticMemberType(), createStringMetadata(), llvm::DIBuilder::createStructType(), llvm::DIBuilder::createSubroutineType(), llvm::MDBuilder::createTBAAAccessTag(), llvm::MDBuilder::createTBAANode(), llvm::MDBuilder::createTBAARoot(), llvm::MDBuilder::createTBAAScalarTypeNode(), llvm::MDBuilder::createTBAAStructNode(), llvm::MDBuilder::createTBAAStructTagNode(), llvm::MDBuilder::createTBAAStructTypeNode(), llvm::MDBuilder::createTBAATypeNode(), llvm::DIBuilder::createTemplateParameterPack(), llvm::DIBuilder::createTemplateTypeParameter(), createTemplateValueParameterHelper(), llvm::DIBuilder::createTypedef(), llvm::DIBuilder::createUnionType(), llvm::MDBuilder::createUnpredictable(), llvm::DIBuilder::createUnspecifiedType(), llvm::DIBuilder::createVariantMemberType(), llvm::DIBuilder::createVariantPart(), llvm::DIBuilder::createVectorType(), llvm::createX86PadShortFunctions(), DisableAllLoopOptsOnLoop(), llvm::SIFrameLowering::eliminateCallFramePseudoInstr(), llvm::SIRegisterInfo::eliminateFrameIndex(), emitClzero(), llvm::SIFrameLowering::emitEntryFunctionPrologue(), llvm::SIFrameLowering::emitEpilogue(), llvm::AArch64FrameLowering::emitEpilogue(), llvm::ARCFrameLowering::emitEpilogue(), llvm::SIFrameLowering::emitPrologue(), llvm::SystemZFrameLowering::emitPrologue(), extractMDNode(), llvm::DIBuilder::finalize(), llvm::DIBuilder::finalizeSubprogram(), findBasePointer(), foldCtpop(), foldCttzCtlz(), llvm::DebugLoc::get(), llvm::DILocation::getMergedLocation(), getMostGenericRange(), getMulHu(), getNewValueJumpOpcode(), llvm::DIBuilder::getOrCreateSubrange(), llvm::DIBuilder::getOrCreateTypeArray(), getOrSelfReference(), getSubprogram(), hasOnlyUniformBranches(), INITIALIZE_PASS(), InsertReturnAddressAuth(), instrumentMaskedLoadOrStore(), isKnownTypeIdMember(), LLVMDIBuilderCreateDebugLocation(), LLVMMDNodeInContext(), llvm::makeFollowupLoopID(), llvm::SIRegisterInfo::materializeFrameBaseRegister(), llvm::LoopVersioning::prepareNoAliasMetadata(), llvm::DIExpression::prependOpcodes(), PushArgMD(), llvm::ARMTargetLowering::ReplaceNodeResults(), llvm::DIBuilder::replaceTemporary(), llvm::SIRegisterInfo::restoreSGPR(), rotateSign(), llvm::CGProfilePass::run(), llvm::WholeProgramDevirtPass::run(), selectJumpTableArmEncoding(), llvm::Loop::setLoopAlreadyUnrolled(), setNoClobberMetadata(), setUniformMetadata(), shouldInstrumentBlock(), llvm::SIRegisterInfo::spillSGPR(), splitGlobal(), StackMallocSizeClass(), llvm::StripDebugInfo(), stripDebugLocFromLoopID(), llvm::Instruction::swapProfMetadata(), llvm::DISubprogram::toSPFlags(), transferSRADebugInfo(), TryToShrinkGlobalToBoolean(), llvm::uniteAccessGroups(), llvm::Instruction::updateProfWeight(), llvm::UpgradeModuleFlags(), llvm::UpgradeRetainReleaseMarker(), llvm::UpgradeTBAANode(), llvm::LoopVectorizeHints::vectorizeAnalysisPassName(), and llvm::InstCombiner::visitCallInst().
|
inline |
Definition at line 924 of file Metadata.h.
References I.
Referenced by llvm::GlobalObject::addMetadata(), llvm::GlobalObject::addTypeMetadata(), llvm::DIExpression::append(), llvm::GlobalObject::clearMetadata(), concatenate(), llvm::GlobalObject::copyMetadata(), createAccessTag(), llvm::DIExpression::createFragmentExpression(), llvm::Instruction::dropUnknownNonDebugMetadata(), llvm::GlobalObject::eraseMetadata(), llvm::Instruction::extractProfTotalWeight(), fixupLineNumbers(), llvm::DebugLoc::get(), llvm::GlobalObject::getAllMetadata(), getIRBForDbgInsertion(), llvm::DILocation::getMergedLocation(), llvm::GlobalObject::getMetadata(), getMostGenericRange(), intersect(), llvm::makeFollowupLoopID(), llvm::DIExpression::prependOpcodes(), printExtendedName(), llvm::Instruction::setAAMetadata(), llvm::GlobalObject::setMetadata(), storeDistinctInContext(), llvm::StripDebugInfo(), stripDebugLocFromLoopID(), llvm::Instruction::swapProfMetadata(), llvm::uniteAccessGroups(), and llvm::UpgradeTBAANode().
|
inlinestatic |
Definition at line 1174 of file Metadata.h.
References llvm::MDTuple::getDistinct().
Referenced by llvm::DebugLoc::appendInlinedAt(), llvm::DICompositeType::buildODRType(), llvm::DIBuilder::createCompileUnit(), llvm::DIBuilder::createGlobalVariableExpression(), llvm::DIBuilder::createLexicalBlock(), fixupLineNumbers(), FunctionNumber(), getSubprogram(), and llvm::StripDebugInfo().
|
inlinestatic |
Definition at line 1170 of file Metadata.h.
References llvm::MDTuple::getIfExists().
Definition at line 923 of file Metadata.cpp.
References concatenate().
Referenced by llvm::combineMetadata(), llvm::Instruction::getAAMetadata(), and llvm::propagateMetadata().
Definition at line 1050 of file Metadata.cpp.
References B, getOperand(), and llvm::ConstantInt::getZExtValue().
Referenced by llvm::combineMetadata().
Definition at line 930 of file Metadata.cpp.
References B, llvm::APFloatBase::cmpLessThan, llvm::APFloat::compare(), and getOperand().
Referenced by llvm::combineMetadata(), and llvm::propagateMetadata().
Definition at line 978 of file Metadata.cpp.
References addRange(), llvm::ConstantAsMetadata::get(), get(), getContext(), getNumOperands(), getOperand(), llvm::ConstantInt::getValue(), I, llvm::ConstantRange::isFullSet(), llvm::SmallVectorTemplateBase< T >::push_back(), llvm::SmallVectorImpl< T >::reserve(), llvm::SmallVectorImpl< T >::resize(), Size, llvm::SmallVectorBase::size(), llvm::APInt::slt(), and tryMergeRange().
Referenced by llvm::combineMetadata().
Definition at line 472 of file TypeBasedAliasAnalysis.cpp.
References matchAccessTags().
Referenced by llvm::combineMetadata(), llvm::Instruction::getAAMetadata(), and llvm::propagateMetadata().
|
inline |
Return number of MDNode operands.
Definition at line 1075 of file Metadata.h.
Referenced by AddRuntimeUnrollDisableMetaData(), llvm::addStringMetadataToLoop(), addToAccessGroupList(), llvm::cacheAnnotationFromMD(), checkMDProf(), CloneAliasScopeMetadata(), llvm::FunctionComparator::cmpMem(), llvm::MDNodeOpsKey::compareOps(), llvm::computeKnownBitsFromRangeMetadata(), llvm::ConstantFoldTerminator(), createAccessTag(), llvm::MDBuilder::createMutableTBAAAccessTag(), llvm::createObjCARCContractPass(), dropAllReferences(), llvm::WebAssemblyAsmPrinter::EmitEndOfAsmFile(), llvm::MachineInstr::emitError(), EmitGCCInlineAsmStr(), llvm::AMDGPU::HSAMD::MetadataStreamerV2::emitKernel(), llvm::AsmPrinter::EmitSpecialLLVMGlobal(), llvm::MDTupleTypedArrayWrapper< T >::empty(), llvm::findOptionMDForLoopID(), llvm::findStringMetadataForLoop(), GetBranchWeights(), llvm::getConstantRangeFromMetadata(), llvm::ProfileSummary::getFromMD(), llvm::Loop::getLoopID(), getMostGenericRange(), llvm::NamedMDNode::getOperand(), getOptimizationFlags(), getOptionalBoolLoopAttribute(), getParentPad(), getSummaryFromMD(), llvm::GetUnrollMetadata(), getVal(), llvm::getValueProfDataFromInst(), llvm::intersectAccessGroups(), isContiguous(), isFuncOrArgAttr(), isKeyValuePair(), isKnownTypeIdMember(), isNewFormatTBAATypeNode(), IsRootTBAANode(), IsScalarTBAANodeImpl(), isStructPathTBAA(), llvm::LTOModule::makeBuffer(), llvm::makeFollowupLoopID(), llvm::DebugInfoFinder::processValue(), rangeMetadataExcludesValue(), setBranchWeights(), llvm::Loop::setLoopAlreadyUnrolled(), llvm::Loop::setLoopID(), llvm::NamedMDNode::setOperand(), llvm::DITypeRefArray::size(), llvm::MDTupleTypedArrayWrapper< T >::size(), srcMgrDiagHandler(), llvm::StripDebugInfo(), llvm::Instruction::swapProfMetadata(), UnrollAndJamCountPragmaValue(), UnrollCountPragmaValue(), llvm::UpgradeModuleFlags(), llvm::UpgradeTBAANode(), llvm::LoopVectorizeHints::vectorizeAnalysisPassName(), llvm::TBAAVerifier::visitTBAAMetadata(), wrapConstantAsMetadata(), and WriteConstantInternal().
Definition at line 1069 of file Metadata.h.
Referenced by AccessQualFromMD(), AddRuntimeUnrollDisableMetaData(), ArgTypeFromMD(), llvm::cacheAnnotationFromMD(), checkMDProf(), CloneAliasScopeMetadata(), llvm::FunctionComparator::cmpMem(), llvm::computeKnownBitsFromRangeMetadata(), llvm::ConstantFoldTerminator(), llvm::MDBuilder::createMutableTBAAAccessTag(), llvm::createObjCARCContractPass(), dropAllReferences(), llvm::WebAssemblyAsmPrinter::EmitEndOfAsmFile(), llvm::MachineInstr::emitError(), EmitGCCInlineAsmStr(), llvm::AMDGPU::HSAMD::MetadataStreamerV2::emitKernel(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), llvm::AsmPrinter::EmitSpecialLLVMGlobal(), llvm::findOptionMDForLoopID(), llvm::findStringMetadataForLoop(), getARClassRegisterMask(), getAssociatedSymbol(), GetBranchWeights(), llvm::getConstantRangeFromMetadata(), llvm::Function::getEntryCount(), llvm::FPMathOperator::getFPAccuracy(), llvm::ProfileSummary::getFromMD(), getIntOperandFromRegisterString(), llvm::Loop::getLoopID(), getMDNodeOperandImpl(), getMostGenericAlignmentOrDereferenceable(), getMostGenericFPMath(), getMostGenericRange(), getOptimizationFlags(), getOptionalBoolLoopAttribute(), getParentPad(), getSummaryFromMD(), llvm::GetUnrollMetadata(), getVal(), llvm::getValueProfDataFromInst(), HasAnyUnrollPragma(), HasBranchWeights(), INITIALIZE_PASS(), isContiguous(), isFuncOrArgAttr(), isKeyValuePair(), isKnownTypeIdMember(), llvm::SelectionDAGISel::IsLegalToFold(), isNewFormatTBAATypeNode(), IsScalarTBAANodeImpl(), isStructPathTBAA(), llvm::LTOModule::makeBuffer(), llvm::makeFollowupLoopID(), llvm::DITypeRefArray::operator[](), llvm::MDTupleTypedArrayWrapper< T >::operator[](), rangeMetadataExcludesValue(), replaceOperandWith(), selectJumpTableArmEncoding(), setBranchWeights(), llvm::Loop::setLoopAlreadyUnrolled(), llvm::Loop::setLoopID(), srcMgrDiagHandler(), llvm::Instruction::swapProfMetadata(), UnrollAndJamCountPragmaValue(), UnrollCountPragmaValue(), llvm::UpgradeModuleFlags(), llvm::UpgradeRetainReleaseMarker(), llvm::UpgradeTBAANode(), llvm::LoopVectorizeHints::vectorizeAnalysisPassName(), llvm::TBAAVerifier::visitTBAAMetadata(), and wrapConstantAsMetadata().
|
inlinestatic |
Definition at line 1178 of file Metadata.h.
References llvm::MDTuple::getTemporary().
Referenced by llvm::MDBuilder::createAnonymousAARoot(), llvm::DIBuilder::createReplaceableCompositeType(), llvm::DIBuilder::createTempFunctionFwdDecl(), llvm::DIBuilder::createTempGlobalVariableFwdDecl(), llvm::DIBuilder::createTempMacroFile(), and stripDebugLocFromLoopID().
Definition at line 910 of file Metadata.cpp.
References getContext(), getOrSelfReference(), llvm::is_contained(), op_begin(), and op_end().
Referenced by llvm::combineMetadata(), llvm::Instruction::getAAMetadata(), and llvm::propagateMetadata().
|
inline |
Definition at line 943 of file Metadata.h.
References llvm::Metadata::Distinct, and llvm::Metadata::Storage.
Referenced by cloneOrBuildODR(), getOptimizationFlags(), hasConflictingReferenceFlags(), isOperandUnresolved(), llvm::ValueEnumerator::print(), rotateSign(), and llvm::StripDebugInfo().
|
inline |
Check if node is fully resolved.
If isTemporary(), this always returns false
; if isDistinct(), this always returns true
.
If isUniqued(), returns true
if this has already dropped RAUW support (because all operands are resolved).
As forward declarations are resolved, their containers should get resolved automatically. However, if this (or one of its operands) is involved in a cycle, resolveCycles() needs to be called explicitly.
Definition at line 940 of file Metadata.h.
Referenced by llvm::DIBuilder::DIBuilder(), dropAllReferences(), llvm::DIBuilder::finalize(), forEachUser(), isOperandUnresolved(), llvm::LexicalScope::LexicalScope(), llvm::DIBuilder::replaceArrays(), llvm::DIBuilder::replaceVTableHolder(), resolve(), resolveCycles(), storeDistinctInContext(), and wrapConstantAsMetadata().
bool MDNode::isTBAAVtableAccess | ( | ) | const |
Check whether MDNode is a vtable access.
Definition at line 449 of file TypeBasedAliasAnalysis.cpp.
References B, isStructPathTBAA(), matchAccessTags(), and llvm::Tag.
|
inline |
Definition at line 944 of file Metadata.h.
References llvm::Metadata::Storage, and llvm::Metadata::Temporary.
Referenced by deleteTemporary(), llvm::DIBuilder::finalizeSubprogram(), forEachUser(), isOperandUnresolved(), and resolve().
|
inline |
Definition at line 942 of file Metadata.h.
References llvm::Metadata::Storage, and llvm::Metadata::Uniqued.
Referenced by dropAllReferences(), isOperandUnresolved(), MDNode(), replaceOperandWith(), resolve(), setOperand(), and wrapConstantAsMetadata().
|
inlineprotected |
Definition at line 893 of file Metadata.h.
Referenced by replaceOperandWith(), and setOperand().
|
inlineprotected |
Definition at line 894 of file Metadata.h.
|
inlineprotected |
Definition at line 898 of file Metadata.h.
Referenced by isOperandUnresolved().
|
inline |
Definition at line 1059 of file Metadata.h.
Referenced by llvm::DITypeRefArray::begin(), llvm::MDTupleTypedArrayWrapper< T >::begin(), llvm::MDNodeOpsKey::calculateHash(), llvm::MDNodeOpsKey::compareOps(), concatenate(), dropAllReferences(), intersect(), llvm::ValueEnumerator::print(), stripDebugLocFromLoopID(), and wrapConstantAsMetadata().
|
inline |
Definition at line 1063 of file Metadata.h.
Referenced by llvm::MDNodeOpsKey::calculateHash(), concatenate(), llvm::DITypeRefArray::end(), llvm::MDTupleTypedArrayWrapper< T >::end(), intersect(), llvm::ValueEnumerator::print(), and stripDebugLocFromLoopID().
|
inline |
Definition at line 1067 of file Metadata.h.
Referenced by addToAccessGroupList(), llvm::TypeFinder::clear(), collectMDInDomain(), llvm::AMDGPU::HSAMD::MetadataStreamerV2::emitKernel(), llvm::TargetLoweringObjectFileELF::emitModuleMetadata(), forEachUser(), getOptimizationFlags(), getSummaryFromMD(), hasConflictingReferenceFlags(), hasSelfReference(), llvm::Loop::isAnnotatedParallel(), isOperandUnresolved(), llvm::makeFollowupLoopID(), llvm::ValueEnumerator::print(), llvm::DIBuilder::replaceVTableHolder(), resolveCycles(), rotateSign(), llvm::StripDebugInfo(), stripDebugLocFromLoopID(), and wrapConstantAsMetadata().
|
protected |
Definition at line 493 of file Metadata.cpp.
References llvm::alignTo(), E, N, and llvm::RISCVFenceField::O.
|
inlineprotected |
Required by std, but never called.
Definition at line 882 of file Metadata.h.
References llvm_unreachable.
Required by std, but never called.
Definition at line 887 of file Metadata.h.
References llvm_unreachable.
|
protected |
Definition at line 481 of file Metadata.cpp.
References llvm::alignTo(), E, llvm::RISCVFenceField::O, and Size.
|
delete |
|
inline |
RAUW a temporary.
true
. Definition at line 949 of file Metadata.h.
References assert().
Referenced by deleteTemporary(), hasSelfReference(), and llvm::DIBuilder::replaceTemporary().
Replace a specific operand.
Definition at line 859 of file Metadata.cpp.
References getOperand(), isUniqued(), mutable_begin(), and setOperand().
Referenced by AddRuntimeUnrollDisableMetaData(), llvm::MDBuilder::createAnonymousAARoot(), DisableAllLoopOptsOnLoop(), llvm::makeFollowupLoopID(), llvm::Loop::setLoopAlreadyUnrolled(), stripDebugLocFromLoopID(), and wrapConstantAsMetadata().
|
inlinestatic |
Replace a temporary node with a distinct one.
Create a distinct version of N
– in place, if possible – and return it. Takes ownership of the temporary node.
Definition at line 994 of file Metadata.h.
References llvm::Metadata::handleChangedOperand(), llvm::Ref, llvm::Metadata::Storage, and llvm::SPII::Store.
Referenced by cloneOrBuildODR(), and llvm::DIBuilder::createArtificialSubprogram().
|
inlinestatic |
Replace a temporary node with a permanent one.
Try to create a uniqued version of N
– in place, if possible – and return it. If N
cannot be uniqued, return a distinct node instead.
Definition at line 972 of file Metadata.h.
|
inlinestatic |
Replace a temporary node with a uniqued one.
Create a uniqued version of N
– in place, if possible – and return it. Takes ownership of the temporary node.
Definition at line 984 of file Metadata.h.
Referenced by createTypeWithFlags(), llvm::DIBuilder::replaceTemporary(), and wrapConstantAsMetadata().
void MDNode::resolve | ( | ) |
Resolve a unique, unresolved node.
Definition at line 576 of file Metadata.cpp.
References assert(), llvm::ContextAndReplaceableUses::hasReplaceableUses(), isOperandUnresolved(), isResolved(), isTemporary(), isUniqued(), and llvm::ContextAndReplaceableUses::takeReplaceableUses().
Referenced by llvm::BTFDebug::BTFDebug(), llvm::BTFTypeDerived::completeType(), dropAllReferences(), llvm::DebugHandlerBase::getBaseTypeSize(), llvm::DbgVariable::getType(), resolveCycles(), shouldAlwaysEmitCompleteClassType(), and shouldEmitUdt().
void MDNode::resolveCycles | ( | ) |
Resolve cycles.
Once all forward declarations have been resolved, force cycles to be resolved.
Definition at line 621 of file Metadata.cpp.
References assert(), isResolved(), N, operands(), and resolve().
Referenced by llvm::DIBuilder::finalize(), and wrapConstantAsMetadata().
Set an operand.
Sets the operand directly, without worrying about uniquing.
Definition at line 871 of file Metadata.cpp.
References assert(), I, isUniqued(), mutable_begin(), and llvm::MDOperand::reset().
Referenced by dropAllReferences(), MDNode(), and replaceOperandWith().
|
protected |
Definition at line 837 of file Metadata.cpp.
References assert(), llvm::Metadata::Distinct, llvm::LLVMContextImpl::DistinctMDNodes, getContext(), llvm::Metadata::getMetadataID(), isResolved(), llvm_unreachable, llvm::LLVMContext::pImpl, and llvm::Metadata::Storage.
Referenced by dropAllReferences(), and isOperandUnresolved().
|
staticprotected |
Definition at line 43 of file MetadataImpl.h.
References llvm::Metadata::Distinct, N, llvm::Metadata::Temporary, and llvm::Metadata::Uniqued.
Referenced by adjustColumn(), llvm::DIFile::getChecksumKind(), and isCanonical().
|
staticprotected |
Definition at line 29 of file MetadataImpl.h.
References llvm::Metadata::Distinct, llvm_unreachable, N, llvm::Metadata::Temporary, and llvm::Metadata::Uniqued.
|
friend |
Definition at line 866 of file Metadata.h.
|
friend |
Definition at line 865 of file Metadata.h.