class TypeFinder
Declaration
class TypeFinder { /* full declaration omitted */ };
Description
TypeFinder - Walk over a module, identifying all of the types that are used by the module.
Declared at: llvm/include/llvm/IR/TypeFinder.h:31
Member Variables
- private DenseSet<const llvm::Value*> VisitedConstants
- private DenseSet<const llvm::MDNode*> VisitedMetadata
- private DenseSet<llvm::AttributeList> VisitedAttributes
- private DenseSet<llvm::Type*> VisitedTypes
- private std::vector<StructType*> StructTypes
- private bool OnlyNamed = false
Method Overview
- public TypeFinder()
- public llvm::TypeFinder::iterator begin()
- public llvm::TypeFinder::const_iterator begin() const
- public void clear()
- public bool empty() const
- public llvm::TypeFinder::iterator end()
- public llvm::TypeFinder::const_iterator end() const
- public llvm::TypeFinder::iterator erase(llvm::TypeFinder::iterator I, llvm::TypeFinder::iterator E)
- public DenseSet<const llvm::MDNode *> & getVisitedMetadata()
- private void incorporateAttributes(llvm::AttributeList AL)
- private void incorporateMDNode(const llvm::MDNode * V)
- private void incorporateType(llvm::Type * Ty)
- private void incorporateValue(const llvm::Value * V)
- public void run(const llvm::Module & M, bool onlyNamed)
- public size_t size() const
Methods
¶TypeFinder()
TypeFinder()
Declared at: llvm/include/llvm/IR/TypeFinder.h:43
¶llvm::TypeFinder::iterator begin()
llvm::TypeFinder::iterator begin()
Declared at: llvm/include/llvm/IR/TypeFinder.h:51
¶llvm::TypeFinder::const_iterator begin() const
llvm::TypeFinder::const_iterator begin() const
Declared at: llvm/include/llvm/IR/TypeFinder.h:54
¶void clear()
void clear()
Declared at: llvm/include/llvm/IR/TypeFinder.h:46
¶bool empty() const
bool empty() const
Declared at: llvm/include/llvm/IR/TypeFinder.h:57
¶llvm::TypeFinder::iterator end()
llvm::TypeFinder::iterator end()
Declared at: llvm/include/llvm/IR/TypeFinder.h:52
¶llvm::TypeFinder::const_iterator end() const
llvm::TypeFinder::const_iterator end() const
Declared at: llvm/include/llvm/IR/TypeFinder.h:55
¶llvm::TypeFinder::iterator erase(
llvm::TypeFinder::iterator I,
llvm::TypeFinder::iterator E)
llvm::TypeFinder::iterator erase(
llvm::TypeFinder::iterator I,
llvm::TypeFinder::iterator E)
Declared at: llvm/include/llvm/IR/TypeFinder.h:59
Parameters
- llvm::TypeFinder::iterator I
- llvm::TypeFinder::iterator E
¶DenseSet<const llvm::MDNode*>&
getVisitedMetadata()
DenseSet<const llvm::MDNode*>&
getVisitedMetadata()
Declared at: llvm/include/llvm/IR/TypeFinder.h:63
¶void incorporateAttributes(llvm::AttributeList AL)
void incorporateAttributes(llvm::AttributeList AL)
Description
Incorporate types referenced by attributes.
Declared at: llvm/include/llvm/IR/TypeFinder.h:81
Parameters
¶void incorporateMDNode(const llvm::MDNode* V)
void incorporateMDNode(const llvm::MDNode* V)
Description
incorporateMDNode - This method is used to walk the operands of an MDNode to find types hiding within.
Declared at: llvm/include/llvm/IR/TypeFinder.h:78
Parameters
- const llvm::MDNode* V
¶void incorporateType(llvm::Type* Ty)
void incorporateType(llvm::Type* Ty)
Description
incorporateType - This method adds the type to the list of used structures if it's not in there already.
Declared at: llvm/include/llvm/IR/TypeFinder.h:68
Parameters
- llvm::Type* Ty
¶void incorporateValue(const llvm::Value* V)
void incorporateValue(const llvm::Value* V)
Description
incorporateValue - This method is used to walk operand lists finding types hiding in constant expressions and other operands that won't be walked in other ways. GlobalValues, basic blocks, instructions, and inst operands are all explicitly enumerated.
Declared at: llvm/include/llvm/IR/TypeFinder.h:74
Parameters
- const llvm::Value* V
¶void run(const llvm::Module& M, bool onlyNamed)
void run(const llvm::Module& M, bool onlyNamed)
Declared at: llvm/include/llvm/IR/TypeFinder.h:45
Parameters
- const llvm::Module& M
- bool onlyNamed
¶size_t size() const
size_t size() const
Declared at: llvm/include/llvm/IR/TypeFinder.h:58