aboutsummaryrefslogtreecommitdiff
path: root/gcc/gimple-pretty-print.c
diff options
context:
space:
mode:
authorMarc Glisse <marc.glisse@inria.fr>2012-08-12 16:20:41 +0000
committerMarc Glisse <marc.glisse@inria.fr>2012-08-12 16:20:41 +0000
commitc9c68dd21a97dcdd018b46112a802c9b5657a1a0 (patch)
tree4ca53bb2e362a9e565642a0de31b1135476a9800 /gcc/gimple-pretty-print.c
parentf7a5deff0ea49ee06f71e03d72ceb9b92d2031c2 (diff)
2012-08-12 Marc Glisse <marc.glisse@inria.fr>
PR middle-end/54193 * gimple-pretty-print.c (dump_ternary_rhs): Handle 4 arguments. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@190328 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gimple-pretty-print.c')
-rw-r--r--gcc/gimple-pretty-print.c26
1 files changed, 17 insertions, 9 deletions
diff --git a/gcc/gimple-pretty-print.c b/gcc/gimple-pretty-print.c
index af7c39a2778..ccf995c4a5d 100644
--- a/gcc/gimple-pretty-print.c
+++ b/gcc/gimple-pretty-print.c
@@ -477,17 +477,25 @@ dump_gimple_assign (pretty_printer *buffer, gimple gs, int spc, int flags)
{
if (flags & TDF_RAW)
{
- tree last;
- if (gimple_num_ops (gs) == 2)
- last = NULL_TREE;
- else if (gimple_num_ops (gs) == 3)
- last = gimple_assign_rhs2 (gs);
- else
- gcc_unreachable ();
+ tree arg1 = NULL;
+ tree arg2 = NULL;
+ tree arg3 = NULL;
+ switch (gimple_num_ops (gs))
+ {
+ case 4:
+ arg3 = gimple_assign_rhs3 (gs);
+ case 3:
+ arg2 = gimple_assign_rhs2 (gs);
+ case 2:
+ arg1 = gimple_assign_rhs1 (gs);
+ break;
+ default:
+ gcc_unreachable ();
+ }
- dump_gimple_fmt (buffer, spc, flags, "%G <%s, %T, %T, %T>", gs,
+ dump_gimple_fmt (buffer, spc, flags, "%G <%s, %T, %T, %T, %T>", gs,
tree_code_name[gimple_assign_rhs_code (gs)],
- gimple_assign_lhs (gs), gimple_assign_rhs1 (gs), last);
+ gimple_assign_lhs (gs), arg1, arg2, arg3);
}
else
{