diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-10 09:27:03 -0800 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-10 09:27:03 -0800 |
commit | 1c4156ffac393a1379ea1674d363e64f0da4a40b (patch) | |
tree | 37f3a42a5c0f6f530a161d14228bee92416f2813 /glsl_parser_extras.cpp | |
parent | 02ae68f496e2dee1c65df4f6194806785c84d67f (diff) |
Use ir_print_visitor to dump IR tree
Diffstat (limited to 'glsl_parser_extras.cpp')
-rw-r--r-- | glsl_parser_extras.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/glsl_parser_extras.cpp b/glsl_parser_extras.cpp index a166fbcd09..caa221f921 100644 --- a/glsl_parser_extras.cpp +++ b/glsl_parser_extras.cpp @@ -35,6 +35,7 @@ #include "glsl_parser_extras.h" #include "glsl_parser.h" #include "symbol_table.h" +#include "ir_print_visitor.h" void _mesa_glsl_error(YYLTYPE *locp, void *state, const char *fmt, ...) @@ -702,6 +703,13 @@ main(int argc, char **argv) ((ast_node *)ptr)->hir(&instructions, &state); } + printf("\n\n"); + foreach_iter(exec_list_iterator, iter, instructions) { + ir_print_visitor v; + + ((ir_instruction *)iter.get())->accept(& v); + } + _mesa_symbol_table_dtor(state.symbols); return 0; |