LLVM API Documentation

Public Types | Public Member Functions | Protected Types | Protected Attributes
llvm::DominanceFrontierBase< BlockT > Class Template Reference

#include <DominanceFrontier.h>

Inheritance diagram for llvm::DominanceFrontierBase< BlockT >:
Inheritance graph
[legend]
Collaboration diagram for llvm::DominanceFrontierBase< BlockT >:
Collaboration graph
[legend]

List of all members.

Public Types

typedef std::set< BlockT * > DomSetType
typedef std::map< BlockT
*, DomSetType
DomSetMapType
typedef DomSetMapType::iterator iterator
typedef
DomSetMapType::const_iterator 
const_iterator

Public Member Functions

 DominanceFrontierBase (bool isPostDom)
const std::vector< BlockT * > & getRoots () const
BlockT * getRoot () const
bool isPostDominator () const
void releaseMemory ()
iterator begin ()
const_iterator begin () const
iterator end ()
const_iterator end () const
iterator find (BlockT *B)
const_iterator find (BlockT *B) const
iterator addBasicBlock (BlockT *BB, const DomSetType &frontier)
void removeBlock (BlockT *BB)
 removeBlock - Remove basic block BB's frontier.
void addToFrontier (iterator I, BlockT *Node)
void removeFromFrontier (iterator I, BlockT *Node)
bool compareDomSet (DomSetType &DS1, const DomSetType &DS2) const
bool compare (DominanceFrontierBase< BlockT > &Other) const
void print (raw_ostream &OS) const
void dump () const
 dump - Dump the dominance frontier to dbgs().

Protected Types

typedef GraphTraits< BlockT * > BlockTraits

Protected Attributes

DomSetMapType Frontiers
std::vector< BlockT * > Roots
const bool IsPostDominators

Detailed Description

template<class BlockT>
class llvm::DominanceFrontierBase< BlockT >

DominanceFrontierBase - Common base class for computing forward and inverse dominance frontiers for a function.

Definition at line 32 of file DominanceFrontier.h.


Member Typedef Documentation

template<class BlockT>
typedef GraphTraits<BlockT *> llvm::DominanceFrontierBase< BlockT >::BlockTraits [protected]

Definition at line 38 of file DominanceFrontier.h.

template<class BlockT>
typedef DomSetMapType::const_iterator llvm::DominanceFrontierBase< BlockT >::const_iterator

Definition at line 72 of file DominanceFrontier.h.

template<class BlockT>
typedef std::map<BlockT *, DomSetType> llvm::DominanceFrontierBase< BlockT >::DomSetMapType

Definition at line 35 of file DominanceFrontier.h.

template<class BlockT>
typedef std::set<BlockT *> llvm::DominanceFrontierBase< BlockT >::DomSetType
template<class BlockT>
typedef DomSetMapType::iterator llvm::DominanceFrontierBase< BlockT >::iterator

Definition at line 71 of file DominanceFrontier.h.


Constructor & Destructor Documentation

template<class BlockT>
llvm::DominanceFrontierBase< BlockT >::DominanceFrontierBase ( bool  isPostDom) [inline]

Definition at line 45 of file DominanceFrontier.h.


Member Function Documentation

template<class BlockT>
iterator llvm::DominanceFrontierBase< BlockT >::addBasicBlock ( BlockT *  BB,
const DomSetType frontier 
) [inline]
template<class BlockT>
void llvm::DominanceFrontierBase< BlockT >::addToFrontier ( iterator  I,
BlockT *  Node 
)
template<class BlockT>
iterator llvm::DominanceFrontierBase< BlockT >::begin ( ) [inline]
template<class BlockT>
const_iterator llvm::DominanceFrontierBase< BlockT >::begin ( ) const [inline]

Definition at line 74 of file DominanceFrontier.h.

template<class BlockT>
bool llvm::DominanceFrontierBase< BlockT >::compare ( DominanceFrontierBase< BlockT > &  Other) const

compare - Return true if the other dominance frontier base matches this dominance frontier base. Otherwise return false.

Definition at line 92 of file DominanceFrontierImpl.h.

References llvm::DominanceFrontierBase< BlockT >::begin(), llvm::DominanceFrontierBase< BlockT >::end(), llvm::sys::path::end(), I, and Node.

Referenced by llvm::MachineDominanceFrontier::compare(), and llvm::DominanceFrontier::compare().

template<class BlockT >
bool llvm::DominanceFrontierBase< BlockT >::compareDomSet ( DomSetType DS1,
const DomSetType DS2 
) const

compareDomSet - Return false if two domsets match. Otherwise return true;

Definition at line 67 of file DominanceFrontierImpl.h.

References I, and Node.

Referenced by llvm::MachineDominanceFrontier::compareDomSet(), and llvm::DominanceFrontier::compareDomSet().

template<class BlockT >
void llvm::DominanceFrontierBase< BlockT >::dump ( ) const

dump - Dump the dominance frontier to dbgs().

Definition at line 146 of file DominanceFrontierImpl.h.

References llvm::dbgs().

template<class BlockT>
iterator llvm::DominanceFrontierBase< BlockT >::end ( ) [inline]
template<class BlockT>
const_iterator llvm::DominanceFrontierBase< BlockT >::end ( ) const [inline]

Definition at line 76 of file DominanceFrontier.h.

template<class BlockT>
iterator llvm::DominanceFrontierBase< BlockT >::find ( BlockT *  B) [inline]
template<class BlockT>
const_iterator llvm::DominanceFrontierBase< BlockT >::find ( BlockT *  B) const [inline]

Definition at line 78 of file DominanceFrontier.h.

template<class BlockT>
BlockT* llvm::DominanceFrontierBase< BlockT >::getRoot ( ) const [inline]
template<class BlockT>
const std::vector<BlockT *>& llvm::DominanceFrontierBase< BlockT >::getRoots ( ) const [inline]

getRoots - Return the root blocks of the current CFG. This may include multiple blocks if we are computing post dominators. For forward dominators, this will always be a single block (the entry node).

Definition at line 51 of file DominanceFrontier.h.

Referenced by llvm::MachineDominanceFrontier::getRoots(), and llvm::DominanceFrontier::getRoots().

template<class BlockT>
bool llvm::DominanceFrontierBase< BlockT >::isPostDominator ( ) const [inline]

isPostDominator - Returns true if analysis based of postdoms

Definition at line 62 of file DominanceFrontier.h.

Referenced by llvm::MachineDominanceFrontier::isPostDominator(), and llvm::DominanceFrontier::isPostDominator().

template<class BlockT >
void llvm::DominanceFrontierBase< BlockT >::print ( raw_ostream OS) const

print - Convert to human readable form

Definition at line 122 of file DominanceFrontierImpl.h.

References llvm::sys::path::begin(), llvm::sys::path::end(), and I.

Referenced by llvm::DominanceFrontier::print().

template<class BlockT>
void llvm::DominanceFrontierBase< BlockT >::releaseMemory ( ) [inline]
template<class BlockT>
void llvm::DominanceFrontierBase< BlockT >::removeBlock ( BlockT *  BB)

removeBlock - Remove basic block BB's frontier.

Definition at line 43 of file DominanceFrontierImpl.h.

References llvm::sys::path::begin(), llvm::sys::path::end(), and I.

Referenced by llvm::MachineDominanceFrontier::removeBlock(), and llvm::DominanceFrontier::removeBlock().

template<class BlockT>
void llvm::DominanceFrontierBase< BlockT >::removeFromFrontier ( iterator  I,
BlockT *  Node 
)

Member Data Documentation

template<class BlockT>
DomSetMapType llvm::DominanceFrontierBase< BlockT >::Frontiers [protected]
template<class BlockT>
const bool llvm::DominanceFrontierBase< BlockT >::IsPostDominators [protected]
template<class BlockT>
std::vector<BlockT *> llvm::DominanceFrontierBase< BlockT >::Roots [protected]

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