LLVM API Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Namespaces | Macros | Functions
RegionIterator.h File Reference
#include "llvm/ADT/GraphTraits.h"
#include "llvm/ADT/PointerIntPair.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/Analysis/RegionInfo.h"
#include "llvm/Support/CFG.h"
#include "llvm/Support/raw_ostream.h"
Include dependency graph for RegionIterator.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  llvm::RNSuccIterator< NodeType >
 Hierarchical RegionNode successor iterator. More...
 
class  llvm::RNSuccIterator< FlatIt< NodeType > >
 Flat RegionNode iterator. More...
 
struct  llvm::GraphTraits< RegionInfo * >
 

Namespaces

 llvm
 List of target independent CodeGen pass IDs.
 

Macros

#define RegionNodeGraphTraits(NodeT)
 
#define RegionGraphTraits(RegionT, NodeT)
 

Functions

template<class NodeType >
RNSuccIterator< NodeType > llvm::succ_begin (NodeType *Node)
 
template<class NodeType >
RNSuccIterator< NodeType > llvm::succ_end (NodeType *Node)
 
 llvm::RegionNodeGraphTraits (RegionNode)
 
 llvm::RegionGraphTraits (Region, RegionNode)
 

Macro Definition Documentation

#define RegionGraphTraits (   RegionT,
  NodeT 
)
Value:
template<> struct GraphTraits<RegionT*> \
: public GraphTraits<NodeT*> { \
typedef df_iterator<NodeType*> nodes_iterator; \
static NodeType *getEntryNode(RegionT* R) { \
return R->getNode(R->getEntry()); \
} \
static nodes_iterator nodes_begin(RegionT* R) { \
return nodes_iterator::begin(getEntryNode(R)); \
} \
static nodes_iterator nodes_end(RegionT* R) { \
return nodes_iterator::end(getEntryNode(R)); \
} \
}; \
template<> struct GraphTraits<FlatIt<RegionT*> > \
: public GraphTraits<FlatIt<NodeT*> > { \
typedef df_iterator<NodeType*, SmallPtrSet<NodeType*, 8>, false, \
GraphTraits<FlatIt<NodeType*> > > nodes_iterator; \
static NodeType *getEntryNode(RegionT* R) { \
return R->getBBNode(R->getEntry()); \
} \
static nodes_iterator nodes_begin(RegionT* R) { \
return nodes_iterator::begin(getEntryNode(R)); \
} \
static nodes_iterator nodes_end(RegionT* R) { \
return nodes_iterator::end(getEntryNode(R)); \
} \
}
const_iterator end(StringRef path)
Get end iterator over path.
Definition: Path.cpp:181
const_iterator begin(StringRef path)
Get begin iterator over path.
Definition: Path.cpp:173

Definition at line 289 of file RegionIterator.h.

#define RegionNodeGraphTraits (   NodeT)
Value:
template<> struct GraphTraits<NodeT*> { \
typedef NodeT NodeType; \
typedef RNSuccIterator<NodeType> ChildIteratorType; \
static NodeType *getEntryNode(NodeType* N) { return N; } \
static inline ChildIteratorType child_begin(NodeType *N) { \
return RNSuccIterator<NodeType>(N); \
} \
static inline ChildIteratorType child_end(NodeType *N) { \
return RNSuccIterator<NodeType>(N, true); \
} \
}; \
template<> struct GraphTraits<FlatIt<NodeT*> > { \
typedef NodeT NodeType; \
typedef RNSuccIterator<FlatIt<NodeT> > ChildIteratorType; \
static NodeType *getEntryNode(NodeType* N) { return N; } \
static inline ChildIteratorType child_begin(NodeType *N) { \
return RNSuccIterator<FlatIt<NodeType> >(N); \
} \
static inline ChildIteratorType child_end(NodeType *N) { \
return RNSuccIterator<FlatIt<NodeType> >(N, true); \
} \
}
#define N

Definition at line 265 of file RegionIterator.h.