From 4ea1df63a99fe3e9bf8f0395cdf33c39d4a2c677 Mon Sep 17 00:00:00 2001 From: Boris Boesler Date: Thu, 6 Jul 2000 08:13:36 +0000 Subject: [PATCH] added vrfy_graph() after maturing the end block [r26] --- testprograms/array-heap_example.c | 5 ++++- testprograms/array-stack_example.c | 5 ++++- testprograms/call_str_example.c | 7 ++++--- testprograms/cond_example.c | 7 ++++--- testprograms/const_eval_example.c | 5 ++++- testprograms/dead_block_example.c | 5 ++++- testprograms/empty.c | 5 +++-- testprograms/global_var_example.c | 5 +++-- testprograms/if_else_example.c | 7 ++++--- testprograms/if_example.c | 5 ++++- testprograms/if_while_example.c | 5 ++++- testprograms/irr_cf_example.c | 5 ++++- testprograms/irr_loop_example.c | 5 ++++- testprograms/memory_example.c | 5 ++++- testprograms/oo_program_example.c | 5 ++++- 15 files changed, 58 insertions(+), 23 deletions(-) diff --git a/testprograms/array-heap_example.c b/testprograms/array-heap_example.c index 203e45573..101a0603c 100644 --- a/testprograms/array-heap_example.c +++ b/testprograms/array-heap_example.c @@ -141,13 +141,16 @@ main(void) add_in_edge (main_irg->end_block, x); mature_block (main_irg->end_block); + /* verify the graph */ + vrfy_graph(main_irg); + printf("\nDone building the graph.\n"); printf("Dumping the graph and a type graph.\n"); dump_ir_block_graph (main_irg); dump_type_graph(main_irg); printf("\nuse xvcg to view these graphs:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (1); } diff --git a/testprograms/array-stack_example.c b/testprograms/array-stack_example.c index f23d08017..1cad06342 100644 --- a/testprograms/array-stack_example.c +++ b/testprograms/array-stack_example.c @@ -127,13 +127,16 @@ main(void) add_in_edge (main_irg->end_block, x); mature_block (main_irg->end_block); + /* verify the graph */ + vrfy_graph(main_irg); + printf("\nDone building the graph.\n"); printf("Dumping the graph and a type graph.\n"); dump_ir_block_graph (main_irg); dump_type_graph(main_irg); printf("\nuse xvcg to view these graphs:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (1); } diff --git a/testprograms/call_str_example.c b/testprograms/call_str_example.c index 6d78e37a8..593a2e894 100644 --- a/testprograms/call_str_example.c +++ b/testprograms/call_str_example.c @@ -92,13 +92,14 @@ int main(int argc, char **argv) /* Now we can mature the end block as all it's predecessors are known. */ mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); - - } diff --git a/testprograms/cond_example.c b/testprograms/cond_example.c index 96e9bf1c0..2c630b7c5 100644 --- a/testprograms/cond_example.c +++ b/testprograms/cond_example.c @@ -113,13 +113,14 @@ int main(int argc, char **argv) /* Now we can mature the end block as all it's predecessors are known. */ mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); - - } diff --git a/testprograms/const_eval_example.c b/testprograms/const_eval_example.c index 036e98c68..3ae9f35fb 100644 --- a/testprograms/const_eval_example.c +++ b/testprograms/const_eval_example.c @@ -67,11 +67,14 @@ main(void) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/dead_block_example.c b/testprograms/dead_block_example.c index 2ff7b3119..c224d9d5d 100644 --- a/testprograms/dead_block_example.c +++ b/testprograms/dead_block_example.c @@ -123,13 +123,16 @@ int main(int argc, char **argv) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph.\n"); printf("Dumping the graph and a control flow graph.\n"); dump_ir_block_graph (irg); dump_cfg (irg); printf("use xvcg to view these graphs:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/empty.c b/testprograms/empty.c index 117b1d03c..b414aa9c5 100644 --- a/testprograms/empty.c +++ b/testprograms/empty.c @@ -82,6 +82,9 @@ int main(int argc, char **argv) /* Now we can mature the end block as all it's predecessors are known. */ mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); @@ -89,6 +92,4 @@ int main(int argc, char **argv) printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); - - } diff --git a/testprograms/global_var_example.c b/testprograms/global_var_example.c index 741f2194d..c1ababb44 100644 --- a/testprograms/global_var_example.c +++ b/testprograms/global_var_example.c @@ -105,6 +105,9 @@ int main(int argc, char **argv) /* Now we can mature the end block as all it's predecessors are known. */ mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); dump_ir_graph_w_types (irg); @@ -113,6 +116,4 @@ int main(int argc, char **argv) printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); - - } diff --git a/testprograms/if_else_example.c b/testprograms/if_else_example.c index 8252950c2..837843c46 100644 --- a/testprograms/if_else_example.c +++ b/testprograms/if_else_example.c @@ -119,13 +119,14 @@ int main(int argc, char **argv) /* Now we can mature the end block as all it's predecessors are known. */ mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); - - } diff --git a/testprograms/if_example.c b/testprograms/if_example.c index d3ca04040..caaddab19 100644 --- a/testprograms/if_example.c +++ b/testprograms/if_example.c @@ -113,13 +113,16 @@ main(void) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + /* output the vcg file */ printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/if_while_example.c b/testprograms/if_while_example.c index 75b6eb21e..1d418f940 100644 --- a/testprograms/if_while_example.c +++ b/testprograms/if_while_example.c @@ -111,12 +111,15 @@ main(void) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + /* output the vcg file */ printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/irr_cf_example.c b/testprograms/irr_cf_example.c index d461668a4..9056fc103 100644 --- a/testprograms/irr_cf_example.c +++ b/testprograms/irr_cf_example.c @@ -123,13 +123,16 @@ int main(int argc, char **argv) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph.\n"); printf("Dumping the graph and a control flow graph.\n"); dump_ir_block_graph (irg); dump_cfg (irg); printf("use xvcg to view these graphs:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/irr_loop_example.c b/testprograms/irr_loop_example.c index b567cc957..51f63be17 100644 --- a/testprograms/irr_loop_example.c +++ b/testprograms/irr_loop_example.c @@ -111,13 +111,16 @@ int main(int argc, char **argv) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph..\n"); printf("Dumping the graph and a control flow graph.\n"); dump_ir_block_graph (irg); dump_cfg (irg); printf("use xvcg to view these graphs:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/memory_example.c b/testprograms/memory_example.c index 4b0c85041..8434f26ee 100644 --- a/testprograms/memory_example.c +++ b/testprograms/memory_example.c @@ -131,11 +131,14 @@ main(void) add_in_edge (irg->end_block, x); mature_block (irg->end_block); + /* verify the graph */ + vrfy_graph(irg); + printf("\nDone building the graph. Dumping it.\n"); dump_ir_block_graph (irg); printf("use xvcg to view this graph:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (0); } diff --git a/testprograms/oo_program_example.c b/testprograms/oo_program_example.c index a45e4c9b1..7365d53c4 100644 --- a/testprograms/oo_program_example.c +++ b/testprograms/oo_program_example.c @@ -200,6 +200,9 @@ main(void) add_in_edge (c_irg->end_block, x); mature_block (c_irg->end_block); + /* verify the graph */ + vrfy_graph(main_irg); + printf("\nDone building the graph.\n"); printf("Dumping the graph and a type graph.\n"); dump_ir_block_graph (c_irg); @@ -208,7 +211,7 @@ main(void) /****************************************************************************/ printf("\nuse xvcg to view these graphs:\n"); - printf("/ben/trapp/bin/i486/xvcg GRAPHNAME\n"); + printf("/ben/goetz/bin/xvcg GRAPHNAME\n"); return (1); } -- 2.20.1