LLVM API Documentation
#include <ValueEnumerator.h>
Definition at line 40 of file ValueEnumerator.h.
typedef std::vector<Type*> llvm::ValueEnumerator::TypeList |
Definition at line 42 of file ValueEnumerator.h.
typedef std::vector<std::pair<const Value*, unsigned> > llvm::ValueEnumerator::ValueList |
Definition at line 45 of file ValueEnumerator.h.
ValueEnumerator - Enumerate module-level information.
Definition at line 279 of file ValueEnumerator.cpp.
References llvm::ARM_PROC::A, llvm::Module::alias_begin(), llvm::Module::alias_end(), llvm::Module::begin(), llvm::SmallVectorImpl< T >::clear(), llvm::Module::end(), F(), getAttributes(), llvm::Module::getValueSymbolTable(), llvm::Module::global_begin(), llvm::Module::global_end(), I, predictUseListOrder(), llvm::shouldPreserveBitcodeUseListOrder(), llvm::SmallVectorTemplateCommon< T >::size(), and UseListOrders.
void ValueEnumerator::dump | ( | ) | const |
Definition at line 393 of file ValueEnumerator.cpp.
References llvm::dbgs(), and print().
unsigned llvm::ValueEnumerator::getAttributeGroupID | ( | AttributeSet | PAL | ) | const [inline] |
Definition at line 122 of file ValueEnumerator.h.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::find(), I, and llvm::AttributeSet::isEmpty().
Referenced by WriteAttributeGroupTable(), and WriteAttributeTable().
const std::vector<AttributeSet>& llvm::ValueEnumerator::getAttributeGroups | ( | ) | const [inline] |
Definition at line 148 of file ValueEnumerator.h.
Referenced by WriteAttributeGroupTable().
unsigned llvm::ValueEnumerator::getAttributeID | ( | AttributeSet | PAL | ) | const [inline] |
Definition at line 115 of file ValueEnumerator.h.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::find(), I, and llvm::AttributeSet::isEmpty().
Referenced by WriteInstruction(), and WriteModuleInfo().
const std::vector<AttributeSet>& llvm::ValueEnumerator::getAttributes | ( | ) | const [inline] |
Definition at line 145 of file ValueEnumerator.h.
Referenced by ValueEnumerator(), and WriteAttributeTable().
const std::vector<const BasicBlock*>& llvm::ValueEnumerator::getBasicBlocks | ( | ) | const [inline] |
Definition at line 142 of file ValueEnumerator.h.
Referenced by WriteFunction().
unsigned ValueEnumerator::getComdatID | ( | const Comdat * | C | ) | const |
Definition at line 371 of file ValueEnumerator.cpp.
References llvm::UniqueVector< T >::idFor().
Referenced by WriteModuleInfo().
const ComdatSetType& llvm::ValueEnumerator::getComdats | ( | ) | const [inline] |
Definition at line 152 of file ValueEnumerator.h.
Referenced by writeComdats().
void llvm::ValueEnumerator::getFunctionConstantRange | ( | unsigned & | Start, |
unsigned & | End | ||
) | const [inline] |
getFunctionConstantRange - Return the range of values that corresponds to function-local constants.
Definition at line 131 of file ValueEnumerator.h.
Referenced by WriteFunction().
const SmallVectorImpl<const MDNode *>& llvm::ValueEnumerator::getFunctionLocalMDValues | ( | ) | const [inline] |
Definition at line 138 of file ValueEnumerator.h.
Referenced by WriteFunctionLocalMetadata().
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 789 of file ValueEnumerator.cpp.
References llvm::BasicBlock::getParent(), and IncorporateFunctionInfoGlobalBBIDs().
Referenced by WriteConstants().
unsigned ValueEnumerator::getInstructionID | ( | const Instruction * | I | ) | const |
Definition at line 365 of file ValueEnumerator.cpp.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::find(), and I.
Referenced by WriteMetadataAttachment().
const ValueList& llvm::ValueEnumerator::getMDValues | ( | ) | const [inline] |
Definition at line 137 of file ValueEnumerator.h.
Referenced by WriteModuleMetadata().
unsigned llvm::ValueEnumerator::getTypeID | ( | Type * | T | ) | const [inline] |
Definition at line 106 of file ValueEnumerator.h.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::find(), and I.
Referenced by PushValueAndType(), WriteConstants(), WriteInstruction(), WriteMDNode(), WriteModuleInfo(), and WriteTypeTable().
const TypeList& llvm::ValueEnumerator::getTypes | ( | ) | const [inline] |
Definition at line 141 of file ValueEnumerator.h.
Referenced by WriteBlockInfo(), and WriteTypeTable().
unsigned ValueEnumerator::getValueID | ( | const Value * | V | ) | const |
Definition at line 381 of file ValueEnumerator.cpp.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::ValueMap< KeyT, ValueT, Config >::end(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::find(), llvm::ValueMap< KeyT, ValueT, Config >::find(), and I.
Referenced by pushValue(), PushValueAndType(), pushValueSigned(), WriteConstants(), WriteFunction(), WriteInstruction(), WriteMDNode(), WriteMetadataAttachment(), WriteModuleInfo(), WriteModuleMetadata(), WriteUseList(), and WriteValueSymbolTable().
const ValueList& llvm::ValueEnumerator::getValues | ( | ) | const [inline] |
Definition at line 136 of file ValueEnumerator.h.
Referenced by WriteConstants(), and WriteModuleConstants().
void ValueEnumerator::incorporateFunction | ( | const Function & | F | ) |
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 700 of file ValueEnumerator.cpp.
References llvm::Function::arg_begin(), llvm::Function::arg_end(), llvm::Function::begin(), llvm::Function::end(), llvm::Function::getAttributes(), llvm::MDNode::getFunction(), I, llvm::MDNode::isFunctionLocal(), llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back(), and llvm::SmallVectorTemplateCommon< T >::size().
Referenced by WriteFunction().
void ValueEnumerator::print | ( | raw_ostream & | OS, |
const ValueMapType & | Map, | ||
const char * | Name | ||
) | const |
Definition at line 400 of file ValueEnumerator.cpp.
References llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::begin(), llvm::Value::dump(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::end(), llvm::Value::getName(), llvm::Value::hasName(), I, llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::size(), llvm::Value::use_begin(), llvm::Value::use_end(), and llvm::Value::uses().
Referenced by dump().
void ValueEnumerator::purgeFunction | ( | ) |
Remove purged values from the ValueMap.
Definition at line 764 of file ValueEnumerator.cpp.
References llvm::SmallVectorImpl< T >::clear(), llvm::ValueMap< KeyT, ValueT, Config >::erase(), and llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT >::erase().
Referenced by WriteFunction().
void ValueEnumerator::setInstructionID | ( | const Instruction * | I | ) |
Definition at line 47 of file ValueEnumerator.h.
Referenced by ValueEnumerator(), and WriteUseListBlock().