diff options
Diffstat (limited to 'gcc/ddg.c')
-rw-r--r-- | gcc/ddg.c | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/gcc/ddg.c b/gcc/ddg.c index 86ffa1f3161..83dbb2181af 100644 --- a/gcc/ddg.c +++ b/gcc/ddg.c @@ -546,7 +546,7 @@ free_ddg (ddg_ptr g) } void -print_ddg_edge (FILE *dump_file, ddg_edge_ptr e) +print_ddg_edge (FILE *file, ddg_edge_ptr e) { char dep_c; @@ -561,13 +561,13 @@ print_ddg_edge (FILE *dump_file, ddg_edge_ptr e) dep_c = 'T'; } - fprintf (dump_file, " [%d -(%c,%d,%d)-> %d] ", INSN_UID (e->src->insn), + fprintf (file, " [%d -(%c,%d,%d)-> %d] ", INSN_UID (e->src->insn), dep_c, e->latency, e->distance, INSN_UID (e->dest->insn)); } /* Print the DDG nodes with there in/out edges to the dump file. */ void -print_ddg (FILE *dump_file, ddg_ptr g) +print_ddg (FILE *file, ddg_ptr g) { int i; @@ -575,34 +575,34 @@ print_ddg (FILE *dump_file, ddg_ptr g) { ddg_edge_ptr e; - print_rtl_single (dump_file, g->nodes[i].insn); - fprintf (dump_file, "OUT ARCS: "); + print_rtl_single (file, g->nodes[i].insn); + fprintf (file, "OUT ARCS: "); for (e = g->nodes[i].out; e; e = e->next_out) - print_ddg_edge (dump_file, e); + print_ddg_edge (file, e); - fprintf (dump_file, "\nIN ARCS: "); + fprintf (file, "\nIN ARCS: "); for (e = g->nodes[i].in; e; e = e->next_in) - print_ddg_edge (dump_file, e); + print_ddg_edge (file, e); - fprintf (dump_file, "\n"); + fprintf (file, "\n"); } } /* Print the given DDG in VCG format. */ void -vcg_print_ddg (FILE *dump_file, ddg_ptr g) +vcg_print_ddg (FILE *file, ddg_ptr g) { int src_cuid; - fprintf (dump_file, "graph: {\n"); + fprintf (file, "graph: {\n"); for (src_cuid = 0; src_cuid < g->num_nodes; src_cuid++) { ddg_edge_ptr e; int src_uid = INSN_UID (g->nodes[src_cuid].insn); - fprintf (dump_file, "node: {title: \"%d_%d\" info1: \"", src_cuid, src_uid); - print_rtl_single (dump_file, g->nodes[src_cuid].insn); - fprintf (dump_file, "\"}\n"); + fprintf (file, "node: {title: \"%d_%d\" info1: \"", src_cuid, src_uid); + print_rtl_single (file, g->nodes[src_cuid].insn); + fprintf (file, "\"}\n"); for (e = g->nodes[src_cuid].out; e; e = e->next_out) { int dst_uid = INSN_UID (e->dest->insn); @@ -610,16 +610,16 @@ vcg_print_ddg (FILE *dump_file, ddg_ptr g) /* Give the backarcs a different color. */ if (e->distance > 0) - fprintf (dump_file, "backedge: {color: red "); + fprintf (file, "backedge: {color: red "); else - fprintf (dump_file, "edge: { "); + fprintf (file, "edge: { "); - fprintf (dump_file, "sourcename: \"%d_%d\" ", src_cuid, src_uid); - fprintf (dump_file, "targetname: \"%d_%d\" ", dst_cuid, dst_uid); - fprintf (dump_file, "label: \"%d_%d\"}\n", e->latency, e->distance); + fprintf (file, "sourcename: \"%d_%d\" ", src_cuid, src_uid); + fprintf (file, "targetname: \"%d_%d\" ", dst_cuid, dst_uid); + fprintf (file, "label: \"%d_%d\"}\n", e->latency, e->distance); } } - fprintf (dump_file, "}\n"); + fprintf (file, "}\n"); } /* Create an edge and initialize it with given values. */ |