GCC Middle and Back End API Reference
graphds.h File Reference

Go to the source code of this file.

Data Structures

struct  graph_edge
struct  vertex
struct  graph

Typedefs

typedef void(* graphds_edge_callback )(struct graph *, struct graph_edge *)

Functions

struct graphnew_graph (int)
void dump_graph (FILE *, struct graph *)
struct graph_edgeadd_edge (struct graph *, int, int)
void identify_vertices (struct graph *, int, int)
int graphds_dfs (struct graph *, int *, int, vec< int > *, bool, bitmap)
int graphds_scc (struct graph *, bitmap)
void graphds_domtree (struct graph *, int, int *, int *, int *)
void for_each_edge (struct graph *, graphds_edge_callback)
void free_graph (struct graph *g)

Typedef Documentation

typedef void(* graphds_edge_callback)(struct graph *, struct graph_edge *)

Function Documentation

struct graph_edge* add_edge ( struct graph ,
int  ,
int   
)
read
void dump_graph ( FILE *  ,
struct graph  
)
void for_each_edge ( struct graph ,
graphds_edge_callback   
)
void free_graph ( struct graph g)
int graphds_dfs ( struct graph g,
int *  qs,
int  nq,
vec< int > *  qt,
bool  forward,
bitmap  subgraph 
)
Runs dfs search over vertices of G, from NQ vertices in queue QS.
   The vertices in postorder are stored into QT.  If FORWARD is false,
   backward dfs is run.  If SUBGRAPH is not NULL, it specifies the
   subgraph of G to run DFS on.  Returns the number of the components
   of the graph (number of the restarts of DFS).   

References comp, vertex::component, dfs_edge_dest(), dfs_edge_src(), dfs_fst_edge(), dfs_next_edge(), free(), graph::n_vertices, vertex::post, stack, tick, and graph::vertices.

Referenced by build_alias_set_optimal_p(), build_base_obj_set_for_drs(), graphds_domtree(), graphds_scc(), mark_nodes_having_upstream_mem_writes(), and rdg_flag_vertex_and_dependent().

void graphds_domtree ( struct graph g,
int  entry,
int *  parent,
int *  son,
int *  brother 
)
Determines the dominance tree of G (stored in the PARENT, SON and BROTHER
   arrays), where the entry node is ENTRY.   

References changed, free(), graphds_dfs(), graph::n_vertices, postorder, vertex::pred, graph_edge::pred_next, graph_edge::src, tree_nca(), graph::vertices, and vNULL.

Referenced by iterate_fix_dominators().

int graphds_scc ( struct graph ,
bitmap   
)
void identify_vertices ( struct graph ,
int  ,
int   
)
struct graph* new_graph ( int  )
read