diff --git a/tools/qfcc/include/statements.h b/tools/qfcc/include/statements.h index 551252dfc..d7edaa4d5 100644 --- a/tools/qfcc/include/statements.h +++ b/tools/qfcc/include/statements.h @@ -85,7 +85,7 @@ struct expr_s; sblock_t *make_statements (struct expr_s *expr); void print_statement (statement_t *s); -void print_flow (sblock_t *sblock, const char *filename); +void print_sblock (sblock_t *sblock, const char *filename); const char *operand_string (operand_t *op); #endif//statement_h diff --git a/tools/qfcc/source/Makefile.am b/tools/qfcc/source/Makefile.am index 7abd37dd8..f5df1de25 100644 --- a/tools/qfcc/source/Makefile.am +++ b/tools/qfcc/source/Makefile.am @@ -40,7 +40,7 @@ bin_SCRIPTS= qfpreqcc common_src=\ class.c codespace.c constfold.c cpp.c dags.c debug.c def.c defspace.c \ - diagnostic.c dot_dag.c dot_expr.c dot_flow.c emit.c expr.c \ + diagnostic.c dot_dag.c dot_expr.c dot_sblock.c emit.c expr.c \ flow.c function.c grab.c idstuff.c linker.c method.c obj_file.c \ obj_type.c opcodes.c options.c qfcc.c reloc.c set.c shared.c statements.c \ strpool.c struct.c switch.c symtab.c type.c value.c diff --git a/tools/qfcc/source/dot_flow.c b/tools/qfcc/source/dot_sblock.c similarity index 95% rename from tools/qfcc/source/dot_flow.c rename to tools/qfcc/source/dot_sblock.c index 4df3f25c0..87f92468d 100644 --- a/tools/qfcc/source/dot_flow.c +++ b/tools/qfcc/source/dot_sblock.c @@ -1,7 +1,7 @@ /* - dot_flow.c + dot_sblock.c - "emit" flow graphs to dot (graphvis). + "emit" sblock graphs to dot (graphvis). Copyright (C) 2011 Bill Currie @@ -103,12 +103,12 @@ flow_sblock (dstring_t *dstr, sblock_t *sblock, int blockno) } void -print_flow (sblock_t *sblock, const char *filename) +print_sblock (sblock_t *sblock, const char *filename) { int i; dstring_t *dstr = dstring_newstr(); - dasprintf (dstr, "digraph flow_%p {\n", sblock); + dasprintf (dstr, "digraph sblock_%p {\n", sblock); dasprintf (dstr, " layout=dot; rankdir=TB;\n"); for (i = 0; sblock; sblock = sblock->next, i++) flow_sblock (dstr, sblock, i); diff --git a/tools/qfcc/source/function.c b/tools/qfcc/source/function.c index ced13bcaf..e862915fd 100644 --- a/tools/qfcc/source/function.c +++ b/tools/qfcc/source/function.c @@ -646,8 +646,8 @@ emit_function (function_t *f, expr_t *e) flow_build_vars (f); flow_build_graph (f); if (options.block_dot.flow) - print_flow (f->sblock, nva ("%s.%s.%s.dot", GETSTR (pr.source_file), - f->name, "flow")); + print_sblock (f->sblock, nva ("%s.%s.%s.dot", GETSTR (pr.source_file), + f->name, "flow")); { flowloop_t *l; int n = 0; diff --git a/tools/qfcc/source/statements.c b/tools/qfcc/source/statements.c index d727d1fcc..ba3bf1f67 100644 --- a/tools/qfcc/source/statements.c +++ b/tools/qfcc/source/statements.c @@ -1177,7 +1177,7 @@ dump_flow (sblock_t *sblock, const char *stage) fname = nva ("%s.%s.%s.dot", GETSTR (pr.source_file), current_func->name, stage); - print_flow (sblock, fname); + print_sblock (sblock, fname); free (fname); }