LLVM 18.0.0git
|
#include "Bitcode/Writer/ValueEnumerator.h"
Public Types | |
using | TypeList = std::vector< Type * > |
using | ValueList = std::vector< std::pair< const Value *, unsigned > > |
using | IndexAndAttrSet = std::pair< unsigned, AttributeSet > |
Attribute groups as encoded in bitcode are almost AttributeSets, but they include the AttributeList index, so we have to track that in our map. | |
Public Attributes | |
UseListOrderStack | UseListOrders |
Definition at line 43 of file ValueEnumerator.h.
using llvm::ValueEnumerator::IndexAndAttrSet = std::pair<unsigned, AttributeSet> |
Attribute groups as encoded in bitcode are almost AttributeSets, but they include the AttributeList index, so we have to track that in our map.
Definition at line 52 of file ValueEnumerator.h.
using llvm::ValueEnumerator::TypeList = std::vector<Type *> |
Definition at line 45 of file ValueEnumerator.h.
using llvm::ValueEnumerator::ValueList = std::vector<std::pair<const Value *, unsigned> > |
Definition at line 48 of file ValueEnumerator.h.
Definition at line 322 of file ValueEnumerator.cpp.
References A, llvm::SmallVectorImpl< T >::clear(), F, llvm::AttributeList::FunctionIndex, GEP, llvm::Type::getMetadataTy(), I, predictUseListOrder(), and UseListOrders.
|
delete |
uint64_t ValueEnumerator::computeBitsRequiredForTypeIndicies | ( | ) | const |
Definition at line 1141 of file ValueEnumerator.cpp.
References getTypes(), llvm::Log2_32_Ceil(), and llvm::size().
LLVM_DUMP_METHOD void ValueEnumerator::dump | ( | ) | const |
Definition at line 492 of file ValueEnumerator.cpp.
References llvm::dbgs(), and print().
|
inline |
Definition at line 182 of file ValueEnumerator.h.
|
inline |
Definition at line 220 of file ValueEnumerator.h.
|
inline |
Definition at line 175 of file ValueEnumerator.h.
References assert(), I, and llvm::AttributeList::isEmpty().
|
inline |
Definition at line 218 of file ValueEnumerator.h.
|
inline |
Definition at line 214 of file ValueEnumerator.h.
Definition at line 472 of file ValueEnumerator.cpp.
References assert(), llvm::CallingConv::C, and llvm::UniqueVector< T >::idFor().
|
inline |
Definition at line 224 of file ValueEnumerator.h.
|
inline |
getFunctionConstantRange - Return the range of values that corresponds to function-local constants.
Definition at line 192 of file ValueEnumerator.h.
References End.
unsigned ValueEnumerator::getGlobalBasicBlockID | ( | const BasicBlock * | BB | ) | const |
getGlobalBasicBlockID - This returns the function-specific ID for the specified basic block.
This is relatively expensive information, so it should only be used by rare constructs such as address-of-label.
Definition at line 1132 of file ValueEnumerator.cpp.
References getGlobalBasicBlockID(), llvm::BasicBlock::getParent(), Idx, and IncorporateFunctionInfoGlobalBBIDs().
Referenced by getGlobalBasicBlockID().
unsigned ValueEnumerator::getInstructionID | ( | const Instruction * | I | ) | const |
Definition at line 466 of file ValueEnumerator.cpp.
References assert(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::find(), and I.
Get the MDString metadata for this block.
Definition at line 203 of file ValueEnumerator.h.
References llvm::ArrayRef< T >::slice().
Definition at line 152 of file ValueEnumerator.h.
References assert(), and getMetadataOrNullID().
Referenced by getValueID().
Definition at line 158 of file ValueEnumerator.h.
Referenced by getMetadataID().
Get the non-MDString metadata for this block.
Definition at line 208 of file ValueEnumerator.h.
References llvm::ArrayRef< T >::slice().
Definition at line 166 of file ValueEnumerator.h.
References assert(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::find(), and I.
Definition at line 212 of file ValueEnumerator.h.
Referenced by computeBitsRequiredForTypeIndicies().
Definition at line 482 of file ValueEnumerator.cpp.
References assert(), llvm::ValueMap< KeyT, ValueT, Config >::end(), llvm::ValueMap< KeyT, ValueT, Config >::find(), getMetadataID(), and I.
Referenced by writeTypeIdCompatibleVtableSummaryRecord().
Definition at line 197 of file ValueEnumerator.h.
|
inline |
Check whether the current block has any metadata to emit.
Definition at line 200 of file ValueEnumerator.h.
incorporateFunction/purgeFunction - If you'd like to deal with a function, use these two methods to get its data into the ValueEnumerator!
Definition at line 1022 of file ValueEnumerator.cpp.
References assert(), llvm::ValueMap< KeyT, ValueT, Config >::count(), F, llvm::DIArgList::getArgs(), I, llvm::SmallVectorTemplateBase< T, bool >::push_back(), and llvm::SmallVectorBase< Size_T >::size().
|
inline |
Definition at line 162 of file ValueEnumerator.h.
|
delete |
void ValueEnumerator::print | ( | raw_ostream & | OS, |
const MetadataMapType & | Map, | ||
const char * | Name | ||
) | const |
Definition at line 527 of file ValueEnumerator.cpp.
References I, Name, OS, and llvm::Metadata::print().
void ValueEnumerator::print | ( | raw_ostream & | OS, |
const ValueMapType & | Map, | ||
const char * | Name | ||
) | const |
Definition at line 500 of file ValueEnumerator.cpp.
References llvm::errs(), I, Name, and OS.
Referenced by dump().
void ValueEnumerator::purgeFunction | ( | ) |
Remove purged values from the ValueMap.
Definition at line 1107 of file ValueEnumerator.cpp.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::erase(), and llvm::ValueMap< KeyT, ValueT, Config >::erase().
void ValueEnumerator::setInstructionID | ( | const Instruction * | I | ) |
Definition at line 478 of file ValueEnumerator.cpp.
References I.
|
inline |
Definition at line 164 of file ValueEnumerator.h.
UseListOrderStack llvm::ValueEnumerator::UseListOrders |
Definition at line 54 of file ValueEnumerator.h.
Referenced by ValueEnumerator(), and llvm::dxil::ValueEnumerator::ValueEnumerator().