diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-25 18:25:37 -0700 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2010-03-25 18:40:48 -0700 |
commit | d7388f389dfd17e3842e5dfda1b5782c00f454e5 (patch) | |
tree | efa62fb79613fffeede738c16d1742563999fffb | |
parent | 8c70a621939e55a81a363f04dee3333772339cbe (diff) |
IR print visitor: print expressions
Not quite complete. The operator is not yet printed.
-rw-r--r-- | ir_print_visitor.cpp | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/ir_print_visitor.cpp b/ir_print_visitor.cpp index 9e4c4412ae..40e3d057db 100644 --- a/ir_print_visitor.cpp +++ b/ir_print_visitor.cpp @@ -90,8 +90,19 @@ void ir_print_visitor::visit(ir_function *ir) void ir_print_visitor::visit(ir_expression *ir) { - printf("%s:%d:\n", __func__, __LINE__); - (void) ir; + printf("(expression "); + + printf("(FINISHME: operator) "); + + printf("("); + if (ir->operands[0]) + ir->operands[0]->accept(this); + printf(") "); + + printf("("); + if (ir->operands[1]) + ir->operands[1]->accept(this); + printf(")) "); } |