LLVM API Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | List of all members
llvm::MapVector< KeyT, ValueT, MapType, VectorType > Class Template Reference

#include <MapVector.h>

Public Types

typedef VectorType::iterator iterator
 
typedef VectorType::const_iterator const_iterator
 

Public Member Functions

SizeType size () const
 
iterator begin ()
 
const_iterator begin () const
 
iterator end ()
 
const_iterator end () const
 
bool empty () const
 
std::pair< KeyT, ValueT > & front ()
 
const std::pair< KeyT, ValueT > & front () const
 
std::pair< KeyT, ValueT > & back ()
 
const std::pair< KeyT, ValueT > & back () const
 
void clear ()
 
ValueT & operator[] (const KeyT &Key)
 
ValueT lookup (const KeyT &Key) const
 
std::pair< iterator, boolinsert (const std::pair< KeyT, ValueT > &KV)
 
unsigned count (const KeyT &Key) const
 
iterator find (const KeyT &Key)
 
const_iterator find (const KeyT &Key) const
 
void pop_back ()
 Remove the last element from the vector. More...
 

Detailed Description

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
class llvm::MapVector< KeyT, ValueT, MapType, VectorType >

This class implements a map that also provides access to all stored values in a deterministic order. The values are kept in a std::vector and the mapping is done with DenseMap from Keys to indexes in that vector.

Definition at line 33 of file MapVector.h.

Member Typedef Documentation

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
typedef VectorType::const_iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::const_iterator

Definition at line 41 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
typedef VectorType::iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::iterator

Definition at line 40 of file MapVector.h.

Member Function Documentation

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
std::pair<KeyT, ValueT>& llvm::MapVector< KeyT, ValueT, MapType, VectorType >::back ( )
inline

Definition at line 69 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
const std::pair<KeyT, ValueT>& llvm::MapVector< KeyT, ValueT, MapType, VectorType >::back ( ) const
inline

Definition at line 70 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::begin ( )
inline
template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
const_iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::begin ( ) const
inline

Definition at line 51 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
void llvm::MapVector< KeyT, ValueT, MapType, VectorType >::clear ( )
inline

Definition at line 72 of file MapVector.h.

Referenced by llvm::ScheduleDAGInstrs::buildSchedGraph().

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
unsigned llvm::MapVector< KeyT, ValueT, MapType, VectorType >::count ( const KeyT Key) const
inline

Definition at line 105 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
bool llvm::MapVector< KeyT, ValueT, MapType, VectorType >::empty ( ) const
inline

Definition at line 63 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::end ( )
inline
template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
const_iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::end ( ) const
inline

Definition at line 59 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::find ( const KeyT Key)
inline

Definition at line 110 of file MapVector.h.

Referenced by llvm::ScheduleDAGInstrs::buildSchedGraph().

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
const_iterator llvm::MapVector< KeyT, ValueT, MapType, VectorType >::find ( const KeyT Key) const
inline

Definition at line 116 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
std::pair<KeyT, ValueT>& llvm::MapVector< KeyT, ValueT, MapType, VectorType >::front ( )
inline

Definition at line 67 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
const std::pair<KeyT, ValueT>& llvm::MapVector< KeyT, ValueT, MapType, VectorType >::front ( ) const
inline

Definition at line 68 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
std::pair<iterator, bool> llvm::MapVector< KeyT, ValueT, MapType, VectorType >::insert ( const std::pair< KeyT, ValueT > &  KV)
inline
template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
ValueT llvm::MapVector< KeyT, ValueT, MapType, VectorType >::lookup ( const KeyT Key) const
inline

Definition at line 88 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
ValueT& llvm::MapVector< KeyT, ValueT, MapType, VectorType >::operator[] ( const KeyT Key)
inline

Definition at line 77 of file MapVector.h.

References I.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
void llvm::MapVector< KeyT, ValueT, MapType, VectorType >::pop_back ( )
inline

Remove the last element from the vector.

Definition at line 123 of file MapVector.h.

template<typename KeyT, typename ValueT, typename MapType = llvm::DenseMap<KeyT, unsigned>, typename VectorType = std::vector<std::pair<KeyT, ValueT> >>
SizeType llvm::MapVector< KeyT, ValueT, MapType, VectorType >::size ( ) const
inline

Definition at line 43 of file MapVector.h.

Referenced by llvm::ScheduleDAGInstrs::buildSchedGraph().


The documentation for this class was generated from the following file: