LLVM 20.0.0git
|
See the file comment. More...
#include "llvm/IR/ValueMap.h"
Public Types | |
using | key_type = KeyT |
using | mapped_type = ValueT |
using | value_type = std::pair< KeyT, ValueT > |
using | size_type = unsigned |
using | iterator = ValueMapIterator< MapT, KeyT > |
using | const_iterator = ValueMapConstIterator< MapT, KeyT > |
Public Member Functions | |
ValueMap (unsigned NumInitBuckets=64) | |
ValueMap (const ExtraData &Data, unsigned NumInitBuckets=64) | |
ValueMap (const ValueMap &)=delete | |
ValueMap (ValueMap &&)=delete | |
ValueMap & | operator= (const ValueMap &)=delete |
ValueMap & | operator= (ValueMap &&)=delete |
bool | hasMD () const |
MDMapT & | MD () |
std::optional< MDMapT > & | getMDMap () |
std::optional< Metadata * > | getMappedMD (const Metadata *MD) const |
Get the mapped metadata, if it's in the map. | |
iterator | begin () |
iterator | end () |
const_iterator | begin () const |
const_iterator | end () const |
bool | empty () const |
size_type | size () const |
void | reserve (size_t Size) |
Grow the map so that it has at least Size buckets. Does not shrink. | |
void | clear () |
size_type | count (const KeyT &Val) const |
Return 1 if the specified key is in the map, 0 otherwise. | |
iterator | find (const KeyT &Val) |
const_iterator | find (const KeyT &Val) const |
ValueT | lookup (const KeyT &Val) const |
lookup - Return the entry for the specified key, or a default constructed value if no such entry exists. | |
std::pair< iterator, bool > | insert (const std::pair< KeyT, ValueT > &KV) |
std::pair< iterator, bool > | insert (std::pair< KeyT, ValueT > &&KV) |
template<typename InputIt > | |
void | insert (InputIt I, InputIt E) |
insert - Range insertion of pairs. | |
bool | erase (const KeyT &Val) |
void | erase (iterator I) |
value_type & | FindAndConstruct (const KeyT &Key) |
ValueT & | operator[] (const KeyT &Key) |
bool | isPointerIntoBucketsArray (const void *Ptr) const |
isPointerIntoBucketsArray - Return true if the specified pointer points somewhere into the ValueMap's array of buckets (i.e. | |
const void * | getPointerIntoBucketsArray () const |
getPointerIntoBucketsArray() - Return an opaque pointer into the buckets array. | |
Friends | |
class | ValueMapCallbackVH< KeyT, ValueT, Config > |
See the file comment.
Definition at line 84 of file ValueMap.h.
using llvm::ValueMap< KeyT, ValueT, Config >::const_iterator = ValueMapConstIterator<MapT, KeyT> |
Definition at line 132 of file ValueMap.h.
using llvm::ValueMap< KeyT, ValueT, Config >::iterator = ValueMapIterator<MapT, KeyT> |
Definition at line 131 of file ValueMap.h.
using llvm::ValueMap< KeyT, ValueT, Config >::key_type = KeyT |
Definition at line 97 of file ValueMap.h.
using llvm::ValueMap< KeyT, ValueT, Config >::mapped_type = ValueT |
Definition at line 98 of file ValueMap.h.
using llvm::ValueMap< KeyT, ValueT, Config >::size_type = unsigned |
Definition at line 100 of file ValueMap.h.
Definition at line 99 of file ValueMap.h.
|
inlineexplicit |
Definition at line 102 of file ValueMap.h.
|
inlineexplicit |
Definition at line 104 of file ValueMap.h.
|
delete |
|
inline |
Definition at line 134 of file ValueMap.h.
Referenced by AddAliasScopeMetadata(), llvm::UnrollAndJamLoop(), and llvm::UnrollLoop().
|
inline |
Definition at line 136 of file ValueMap.h.
|
inline |
Definition at line 145 of file ValueMap.h.
Referenced by llvm::FunctionLoweringInfo::clear(), and llvm::GlobalNumberState::clear().
Return 1 if the specified key is in the map, 0 otherwise.
Definition at line 151 of file ValueMap.h.
Referenced by buildClonedLoops(), llvm::CloneAndPruneIntoFromInst(), llvm::CloneFunction(), llvm::CloneFunctionInto(), llvm::FunctionLoweringInfo::ComputePHILiveOutRegInfo(), llvm::ValueEnumerator::incorporateFunction(), llvm::FunctionLoweringInfo::isExportedInst(), and llvm::updateProfileCallee().
|
inline |
Definition at line 139 of file ValueMap.h.
|
inline |
Definition at line 135 of file ValueMap.h.
Referenced by AddAliasScopeMetadata(), addPHINodeEntriesForMappedBlock(), llvm::JumpThreadingPass::cloneInstructions(), llvm::FunctionLoweringInfo::ComputePHILiveOutRegInfo(), llvm::JumpThreadingPass::duplicateCondBranchOnPHIIntoPred(), llvm::DuplicateInstructionsInSplitBetween(), generateReproducer(), llvm::ValueEnumerator::getValueID(), llvm::insertDebugValuesForPHIs(), llvm::FunctionLoweringInfo::InvalidatePHILiveOutRegInfo(), llvm::AMDGPUPerfHintAnalysis::isMemoryBound(), llvm::AMDGPUPerfHintAnalysis::needsWaveLimiter(), llvm::remapDebugVariable(), llvm::UnrollAndJamLoop(), and llvm::UnrollLoop().
|
inline |
Definition at line 137 of file ValueMap.h.
Definition at line 190 of file ValueMap.h.
References I.
Referenced by CloneLoopBlocks(), llvm::GlobalNumberState::erase(), llvm::ValueEnumerator::purgeFunction(), and llvm::UnrollLoop().
|
inline |
Definition at line 198 of file ValueMap.h.
References I.
Definition at line 155 of file ValueMap.h.
Referenced by addPHINodeEntriesForMappedBlock(), llvm::JumpThreadingPass::cloneInstructions(), llvm::FunctionLoweringInfo::ComputePHILiveOutRegInfo(), llvm::JumpThreadingPass::duplicateCondBranchOnPHIIntoPred(), llvm::DuplicateInstructionsInSplitBetween(), generateReproducer(), llvm::ValueEnumerator::getValueID(), llvm::insertDebugValuesForPHIs(), llvm::FunctionLoweringInfo::InvalidatePHILiveOutRegInfo(), llvm::AMDGPUPerfHintAnalysis::isMemoryBound(), llvm::AMDGPUPerfHintAnalysis::needsWaveLimiter(), llvm::remapDebugVariable(), and llvm::UnrollLoop().
|
inline |
Definition at line 158 of file ValueMap.h.
|
inline |
Definition at line 202 of file ValueMap.h.
|
inline |
Get the mapped metadata, if it's in the map.
Definition at line 122 of file ValueMap.h.
References llvm::ValueMap< KeyT, ValueT, Config >::MD().
|
inline |
Definition at line 119 of file ValueMap.h.
|
inline |
getPointerIntoBucketsArray() - Return an opaque pointer into the buckets array.
In conjunction with the previous method, this can be used to determine whether an insertion caused the ValueMap to reallocate.
Definition at line 220 of file ValueMap.h.
|
inline |
Definition at line 113 of file ValueMap.h.
|
inline |
Definition at line 172 of file ValueMap.h.
Referenced by llvm::orc::cloneToNewContext(), llvm::GlobalNumberState::getNumber(), llvm::ValueMap< KeyT, ValueT, Config >::insert(), llvm::insertDebugValuesForPHIs(), and InsertNewValueIntoMap().
|
inline |
insert - Range insertion of pairs.
Definition at line 185 of file ValueMap.h.
References E, I, and llvm::ValueMap< KeyT, ValueT, Config >::insert().
|
inline |
Definition at line 177 of file ValueMap.h.
|
inline |
isPointerIntoBucketsArray - Return true if the specified pointer points somewhere into the ValueMap's array of buckets (i.e.
either to a key or value in the ValueMap).
Definition at line 213 of file ValueMap.h.
References Ptr.
lookup - Return the entry for the specified key, or a default constructed value if no such entry exists.
Definition at line 164 of file ValueMap.h.
References I.
Referenced by AddParamAndFnBasicAttributes(), AddReturnAttributes(), llvm::OpenMPIRBuilder::applySimd(), buildClonedLoopBlocks(), buildClonedLoops(), llvm::CloneAndPruneIntoFromInst(), cloneConstantExprWithNewAddressSpace(), CloneLoopBlocks(), cloneLoopNest(), ConnectEpilog(), ConnectProlog(), getNewDefiningAccessForClone(), operandWithNewAddressSpaceOrCreatePoison(), RewriteUsesOfClonedInstructions(), llvm::UnrollRuntimeLoopRemainder(), updateCallerBFI(), and llvm::MemorySSAUpdater::updateForClonedLoop().
|
inline |
Definition at line 114 of file ValueMap.h.
Referenced by llvm::CloneFunctionInto(), and llvm::ValueMap< KeyT, ValueT, Config >::getMappedMD().
|
delete |
|
delete |
Definition at line 206 of file ValueMap.h.
|
inline |
Grow the map so that it has at least Size buckets. Does not shrink.
Definition at line 143 of file ValueMap.h.
References Size.
|
inline |
Definition at line 140 of file ValueMap.h.
Referenced by llvm::insertDebugValuesForPHIs().
|
friend |
Definition at line 79 of file ValueMap.h.