![]() |
PandA-2024.02
|
Class specification of the graph structures. More...
#include "edge_info.hpp"#include "graph_info.hpp"#include "node_info.hpp"#include <fstream>#include <ostream>#include "custom_set.hpp"#include <deque>#include <list>#include "exceptions.hpp"#include "refcount.hpp"#include <boost/config.hpp>#include <boost/graph/adjacency_list.hpp>#include <boost/graph/breadth_first_search.hpp>#include <boost/graph/filtered_graph.hpp>#include <boost/graph/graph_utility.hpp>#include <boost/graph/graphviz.hpp>#include <boost/graph/strong_components.hpp>#include <boost/graph/topological_sort.hpp>#include <boost/version.hpp>#include <utility>

Go to the source code of this file.
Data Structures | |
| struct | RawGraph |
| struct | EdgeProperty |
| The property associated with edge. More... | |
| struct | graph_info_t |
| Custom graph property: GraphInfo. More... | |
| struct | graphs_collection |
| bulk graph. More... | |
| struct | undirected_graphs_collection |
| bulk graph. More... | |
| struct | SelectVertex< Graph > |
| Predicate functor object used to select the proper set of vertexes. More... | |
| struct | SelectEdge< Graph > |
| Predicate functor object used to select the proper set of edges. More... | |
| struct | graph |
| General class used to describe a graph in PandA. More... | |
| struct | ugraph |
| General class used to describe a graph in PandA. More... | |
| struct | ltedge< Graph > |
| Functor used to sort edges. More... | |
| struct | std::hash< EdgeDescriptor > |
| class | VertexWriter |
| Functor used to write the content of a vertex to dotty file. More... | |
| class | EdgeWriter |
| Functor used to write the content of the edges to a dotty file. More... | |
| class | GraphWriter |
| Functor used to write the content of the property of a graph to a dotty file. More... | |
| class | UVertexWriter |
| Functor used to write the content of a vertex to dotty file. More... | |
| class | UEdgeWriter |
| Functor used to write the content of the edges to a dotty file. More... | |
Namespaces | |
| std | |
| Definition of hash function for EdgeDescriptor. | |
Macros | |
| #define | GET_RAW_EDGE_INFO(data, edge_info, edge_index) get_edge_info<edge_info>(edge_index, *(data)) |
| #define | CGET_RAW_EDGE_INFO(data, edge_info, edge_index) Cget_edge_info<edge_info>(edge_index, *(data)) |
| #define | boost_CGetOpGraph_property(graph_arg) boost::get_property(graph_arg, graph_info_t()) |
| #define | SET_NODE_INFO_REF(data, NodeInfo, obj, vertex_index) set_node_info<NodeInfo>(vertex_index, obj, *(data)) |
| #define | GET_NODE_INFO_REF(data, NodeInfo, vertex_index) Cget_node_infoRef<NodeInfo>(vertex_index, *(data)) |
| #define | GET_NODE_INFO(data, NodeInfo, vertex_index) get_node_info<NodeInfo>(vertex_index, *(data)) |
| #define | CGET_NODE_INFO(data, NodeInfo, vertex_index) Cget_node_info<NodeInfo>(vertex_index, *(data)) |
| #define | GET_EDGE_INFO(data, edge_info, edge_index) get_edge_info<edge_info>(edge_index, *(data)) |
| #define | CGET_EDGE_INFO(data, edge_info, edge_index) Cget_edge_info<edge_info>(edge_index, *(data)) |
| #define | NULL_VERTEX boost::graph_traits<graph>::null_vertex() |
| null vertex definition More... | |
| #define | NULL_UVERTEX boost::graph_traits<ugraph>::null_vertex() |
| null vertex definition More... | |
| #define | NULL_UGCVERTEX boost::graph_traits<undirected_graphs_collection>::null_vertex() |
Typedefs | |
| using | boost_raw_graph = boost::adjacency_list< boost::listS, boost::listS, boost::bidirectionalS, boost::property< boost::vertex_index_t, std::size_t, NodeInfoRef >, EdgeInfoRef, GraphInfoRef > |
| typedef boost::property< graph_info_t, GraphInfoRef > | GraphProperty |
| typedef boost::adjacency_list< boost::listS, boost::listS, boost::bidirectionalS, boost::property< boost::vertex_index_t, std::size_t, boost::property< boost::vertex_color_t, boost::default_color_type, NodeInfoRef > >, EdgeProperty, GraphProperty > | boost_graphs_collection |
| typedef boost::adjacency_list< boost::listS, boost::listS, boost::undirectedS, boost::property< boost::vertex_index_t, std::size_t, boost::property< boost::vertex_color_t, boost::default_color_type, NodeInfoRef > >, EdgeProperty, GraphProperty > | undirected_boost_graphs_collection |
| using | graphs_collectionRef = refcount< graphs_collection > |
| using | undirected_graphs_collectionRef = refcount< undirected_graphs_collection > |
| using | graphRef = refcount< graph > |
| using | graphConstRef = refcount< const graph > |
| using | ugraphRef = refcount< ugraph > |
| using | vertex = boost::graph_traits< graph >::vertex_descriptor |
| vertex definition. More... | |
| using | VertexIterator = boost::graph_traits< graph >::vertex_iterator |
| vertex_iterator definition. More... | |
| using | InEdgeIterator = boost::graph_traits< graph >::in_edge_iterator |
| in_edge_iterator definition. More... | |
| using | OutEdgeIterator = boost::graph_traits< graph >::out_edge_iterator |
| out_edge_iterator definition. More... | |
| using | EdgeIterator = boost::graph_traits< graph >::edge_iterator |
| edge_iterator definition. More... | |
| using | EdgeDescriptor = boost::graph_traits< graph >::edge_descriptor |
| edge definition. More... | |
| using | uvertex = boost::graph_traits< ugraph >::vertex_descriptor |
| vertex definition. More... | |
| using | UGCvertex = boost::graph_traits< undirected_graphs_collection >::vertex_descriptor |
| vertex definition for undirected_graphs_collection. More... | |
| using | UVertexIterator = boost::graph_traits< ugraph >::vertex_iterator |
| vertex_iterator definition. More... | |
| using | UInEdgeIterator = boost::graph_traits< ugraph >::in_edge_iterator |
| in_edge_iterator definition. More... | |
| using | UOutEdgeIterator = boost::graph_traits< ugraph >::out_edge_iterator |
| out_edge_iterator definition. More... | |
| using | UEdgeIterator = boost::graph_traits< ugraph >::edge_iterator |
| edge_iterator definition. More... | |
| using | UEdgeDescriptor = boost::graph_traits< ugraph >::edge_descriptor |
| edge definition. More... | |
Functions | |
| template<class info_object , class Graph > | |
| info_object * | get_raw_edge_info (typename boost::graph_traits< Graph >::edge_descriptor e, Graph &g) |
| Function returning the edge information associated with the specified edge. More... | |
| template<class info_object , class Graph > | |
| const info_object * | Cget_raw_edge_info (typename boost::graph_traits< Graph >::edge_descriptor e, const Graph &g) |
| Function returning the edge information associated with the specified edge. More... | |
| template<class info_object , class Graph > | |
| NodeInfoRef & | Cget_node_infoRef (typename boost::graph_traits< Graph >::vertex_descriptor v, Graph &g) |
| Function returning the reference to the edge information associated with the specified edge. More... | |
| template<class info_object , class Graph > | |
| void | set_node_info (typename boost::graph_traits< Graph >::vertex_descriptor v, const refcount< info_object > &obj, Graph &g) |
| Function returning the node information associated with the specified node. More... | |
| template<class info_object , class Graph > | |
| info_object * | get_node_info (typename boost::graph_traits< Graph >::vertex_descriptor v, Graph &g) |
| Function returning the node information associated with the specified node. More... | |
| template<class info_object , class Graph > | |
| const info_object * | Cget_node_info (typename boost::graph_traits< Graph >::vertex_descriptor v, const Graph &g) |
| Function returning the node information associated with the specified node. More... | |
| template<class info_object , class Graph > | |
| info_object * | get_edge_info (typename boost::graph_traits< Graph >::edge_descriptor e, Graph &g) |
| Function returning the edge information associated with the specified edge. More... | |
| template<class info_object , class Graph > | |
| const info_object * | Cget_edge_info (typename boost::graph_traits< Graph >::edge_descriptor e, const Graph &g) |
| Function returning the edge information associated with the specified edge. More... | |
| template<typename H > | |
| H | AbslHashValue (const H &h, const EdgeDescriptor &m) |
| boost::graph_traits< graph >::vertex_descriptor | VERTEX (const boost::graph_traits< graph >::vertices_size_type i, const graph &g) |
| Given a filtered graph and an index returns the vertex exploiting the boost::vertex applied on the original graph. More... | |
| boost::graph_traits< ugraph >::vertex_descriptor | VERTEX (const boost::graph_traits< ugraph >::vertices_size_type i, const ugraph &g) |
| Given a filtered ugraph and an index returns the vertex exploiting the boost::vertex applied on the original graph. More... | |
| template<class Graph > | |
| void | ADD_UEDGE (typename boost::graph_traits< Graph >::vertex_descriptor A, typename boost::graph_traits< Graph >::vertex_descriptor B, int selector, Graph &g) |
forward declarations | |
Graph include STD include STL include Utility include | |
| CONSTREF_FORWARD_DECL (EdgeInfo) | |
| CONSTREF_FORWARD_DECL (EdgeWriter) | |
| CONSTREF_FORWARD_DECL (GraphWriter) | |
| CONSTREF_FORWARD_DECL (NodeInfo) | |
| REF_FORWARD_DECL (NodeInfo) | |
| CONSTREF_FORWARD_DECL (Parameter) | |
| CONSTREF_FORWARD_DECL (UEdgeWriter) | |
| CONSTREF_FORWARD_DECL (UVertexWriter) | |
| CONSTREF_FORWARD_DECL (VertexWriter) | |
Class specification of the graph structures.
Definition in file graph.hpp.
| #define boost_CGetOpGraph_property | ( | graph_arg | ) | boost::get_property(graph_arg, graph_info_t()) |
Definition at line 280 of file graph.hpp.
Referenced by graph::CGetGraphInfo(), graph::GetGraphInfo(), and graphs_collection::graphs_collection().
| #define CGET_EDGE_INFO | ( | data, | |
| edge_info, | |||
| edge_index | |||
| ) | Cget_edge_info<edge_info>(edge_index, *(data)) |
| #define CGET_NODE_INFO | ( | data, | |
| NodeInfo, | |||
| vertex_index | |||
| ) | Cget_node_info<NodeInfo>(vertex_index, *(data)) |
| #define CGET_RAW_EDGE_INFO | ( | data, | |
| edge_info, | |||
| edge_index | |||
| ) | Cget_edge_info<edge_info>(edge_index, *(data)) |
| #define GET_EDGE_INFO | ( | data, | |
| edge_info, | |||
| edge_index | |||
| ) | get_edge_info<edge_info>(edge_index, *(data)) |
| #define GET_NODE_INFO | ( | data, | |
| NodeInfo, | |||
| vertex_index | |||
| ) | get_node_info<NodeInfo>(vertex_index, *(data)) |
Definition at line 601 of file graph.hpp.
Referenced by operations_graph_constructor::add_type(), CallGraphManager::AddFunction(), operations_graph_constructor::AddOperation(), and structural_manager::build_graph().
| #define GET_NODE_INFO_REF | ( | data, | |
| NodeInfo, | |||
| vertex_index | |||
| ) | Cget_node_infoRef<NodeInfo>(vertex_index, *(data)) |
| #define GET_RAW_EDGE_INFO | ( | data, | |
| edge_info, | |||
| edge_index | |||
| ) | get_edge_info<edge_info>(edge_index, *(data)) |
| #define NULL_UGCVERTEX boost::graph_traits<undirected_graphs_collection>::null_vertex() |
| #define NULL_UVERTEX boost::graph_traits<ugraph>::null_vertex() |
| #define NULL_VERTEX boost::graph_traits<graph>::null_vertex() |
null vertex definition
Definition at line 1305 of file graph.hpp.
Referenced by HLSFunctionBitValue::ComputeRelationships(), dead_code_eliminationIPA::ComputeRelationships(), BitValueIPA::ComputeRelationships(), create_tree_manager::ComputeRelationships(), TasteInterfaceGeneration::ComputeRelationships(), BuildVirtualPhi::ComputeRelationships(), SDCScheduling::ComputeRelationships(), allocation::ComputeRelationships(), mux_connection_binding::connect_to_registers(), mux_connection_binding::create_connections(), mux_connection_binding::create_single_conn(), fsm_controller::create_state_machine(), HWDiscrepancyAnalysis::Exec(), fun_dominator_allocation::Exec(), liveness::get_name(), TransitionInfo::get_ref_state(), DesignFlowGraphsCollection::GetDesignFlowStep(), DesignFlowManager::GetStatus(), multi_way_if::HasToBeExecuted(), cdfc_module_binding::initialize_connection_relation(), FSM_NI_SSA_liveness::InternalExec(), SerializeMutualExclusions::InternalExec(), OpOrderComputation::InternalExec(), BBOrderComputation::InternalExec(), HLSFunctionBitValue::InternalExec(), mem_dominator_allocation::InternalExec(), cdfc_module_binding::InternalExec(), Loop::IsReducible(), last_intermediate_state::operator()(), next_unique_state::operator()(), Loop::primary_landing_pad(), BehavioralHelper::PrintInit(), cdfc_module_binding::update_slack_starting_time(), EdgeCWriter::writeRoutineInstructions_rec(), and CWriter::writeRoutineInstructions_rec().
| #define SET_NODE_INFO_REF | ( | data, | |
| NodeInfo, | |||
| obj, | |||
| vertex_index | |||
| ) | set_node_info<NodeInfo>(vertex_index, obj, *(data)) |
| typedef boost::adjacency_list< boost::listS, boost::listS, boost::bidirectionalS, boost::property<boost::vertex_index_t, std::size_t, boost::property<boost::vertex_color_t, boost::default_color_type, NodeInfoRef> >, EdgeProperty, GraphProperty> boost_graphs_collection |
| using boost_raw_graph = boost::adjacency_list<boost::listS, boost::listS, boost::bidirectionalS, boost::property<boost::vertex_index_t, std::size_t, NodeInfoRef>, EdgeInfoRef, GraphInfoRef> |
| using EdgeDescriptor = boost::graph_traits<graph>::edge_descriptor |
| using EdgeIterator = boost::graph_traits<graph>::edge_iterator |
| using graphConstRef = refcount<const graph> |
| typedef boost::property<graph_info_t, GraphInfoRef> GraphProperty |
| using InEdgeIterator = boost::graph_traits<graph>::in_edge_iterator |
| using OutEdgeIterator = boost::graph_traits<graph>::out_edge_iterator |
| using UEdgeDescriptor = boost::graph_traits<ugraph>::edge_descriptor |
| using UEdgeIterator = boost::graph_traits<ugraph>::edge_iterator |
| using UGCvertex = boost::graph_traits<undirected_graphs_collection>::vertex_descriptor |
vertex definition for undirected_graphs_collection.
| using UInEdgeIterator = boost::graph_traits<ugraph>::in_edge_iterator |
| typedef boost::adjacency_list< boost::listS, boost::listS, boost::undirectedS, boost::property<boost::vertex_index_t, std::size_t, boost::property<boost::vertex_color_t, boost::default_color_type, NodeInfoRef> >, EdgeProperty, GraphProperty> undirected_boost_graphs_collection |
| using UOutEdgeIterator = boost::graph_traits<ugraph>::out_edge_iterator |
| using UVertexIterator = boost::graph_traits<ugraph>::vertex_iterator |
| using VertexIterator = boost::graph_traits<graph>::vertex_iterator |
| H AbslHashValue | ( | const H & | h, |
| const EdgeDescriptor & | m | ||
| ) |
| const info_object* Cget_edge_info | ( | typename boost::graph_traits< Graph >::edge_descriptor | e, |
| const Graph & | g | ||
| ) |
Function returning the edge information associated with the specified edge.
This function does not modify the graph.
| v | is the considered node. |
| g | is the graph. |
Definition at line 634 of file graph.hpp.
References THROW_ASSERT.
| const info_object* Cget_node_info | ( | typename boost::graph_traits< Graph >::vertex_descriptor | v, |
| const Graph & | g | ||
| ) |
Function returning the node information associated with the specified node.
This function does not modify the graph.
| v | is the considered node. |
| g | is the graph. |
Definition at line 592 of file graph.hpp.
References THROW_ASSERT.
| NodeInfoRef& Cget_node_infoRef | ( | typename boost::graph_traits< Graph >::vertex_descriptor | v, |
| Graph & | g | ||
| ) |
| const info_object* Cget_raw_edge_info | ( | typename boost::graph_traits< Graph >::edge_descriptor | e, |
| const Graph & | g | ||
| ) |
Function returning the edge information associated with the specified edge.
This function does not modify the graph.
| e | is the considered edge. |
| g | is the graph. |
Definition at line 188 of file graph.hpp.
References THROW_ASSERT.
| CONSTREF_FORWARD_DECL | ( | EdgeInfo | ) |
| CONSTREF_FORWARD_DECL | ( | EdgeWriter | ) |
| CONSTREF_FORWARD_DECL | ( | GraphWriter | ) |
| CONSTREF_FORWARD_DECL | ( | NodeInfo | ) |
| CONSTREF_FORWARD_DECL | ( | Parameter | ) |
| CONSTREF_FORWARD_DECL | ( | UEdgeWriter | ) |
| CONSTREF_FORWARD_DECL | ( | UVertexWriter | ) |
| CONSTREF_FORWARD_DECL | ( | VertexWriter | ) |
| info_object* get_edge_info | ( | typename boost::graph_traits< Graph >::edge_descriptor | e, |
| Graph & | g | ||
| ) |
Function returning the edge information associated with the specified edge.
This function modifies the graph if EdgeInfo is not yet associated with the edge.
| e | is the considered edge. |
| g | is the graph. |
Note: reference has to be used since we want to modify the info associated with the edge
Definition at line 613 of file graph.hpp.
References THROW_ASSERT.
| info_object* get_node_info | ( | typename boost::graph_traits< Graph >::vertex_descriptor | v, |
| Graph & | g | ||
| ) |
Function returning the node information associated with the specified node.
This function modifies the graph if NodeInfo is not yet associated with the node.
| v | is the considered node. |
| g | is the graph. |
Definition at line 571 of file graph.hpp.
References THROW_ASSERT.
| info_object* get_raw_edge_info | ( | typename boost::graph_traits< Graph >::edge_descriptor | e, |
| Graph & | g | ||
| ) |
Function returning the edge information associated with the specified edge.
This function modifies the graph if EdgeInfo is not yet associated with the edge.
| e | is the considered edge. |
| g | is the graph. |
Note: reference has to be used since we want to modify the info associated with the edge
Definition at line 167 of file graph.hpp.
References THROW_ASSERT.
| REF_FORWARD_DECL | ( | NodeInfo | ) |
|
inline |
Given a filtered graph and an index returns the vertex exploiting the boost::vertex applied on the original graph.
this function can access the bulk graph
| i | is the index of the vertex. |
| g | is the graph for which the vertex is asked. |
Definition at line 1368 of file graph.hpp.
Referenced by graph::graph(), and ugraph::ugraph().

|
inline |
Given a filtered ugraph and an index returns the vertex exploiting the boost::vertex applied on the original graph.
this function can access the bulk graph
| i | is the index of the vertex. |
| g | is the ugraph for which the vertex is asked. |
1.8.13