1 #ifndef ___________CDG_H__________
2 #define ___________CDG_H__________
5 using namespace StaticCFG;
31 return "case" + caseLabel->unparseToString();
46 typedef boost::graph_traits<ControlDependenceGraph>
GraphTraits;
47 typedef GraphTraits::vertex_descriptor
Vertex;
48 typedef GraphTraits::edge_descriptor
Edge;
54 : cdEdge(edge), cdNode(node) {}
79 ControlDependences getControlDependences(
CFGNodePtr cfgNode);
82 ControlDependences getControlDependences(
SgNode* astNode);
90 void toDot(
const std::string& filename)
const;
94 static void writeGraphEdge(std::ostream& out,
const CDGEdge& edge);
105 std::vector<ControlFlowGraph::Edge> > >
120 writeGraphEdge(out, (*
this)[edge]);
124 void appendSuccessors(
126 std::vector<Vertex>& vertices,
127 const std::map<
Vertex, std::set<Vertex> >& iSucc);
131 const std::map<ControlFlowGraph::Vertex, ControlFlowGraph::Vertex>& iDom,
const ControlFlowGraph&
cfg);