This wraps { ... } in _Literal (type) for consumption by the GIMPLE FE.

Bootstrap & regtest ongoing on x86_64-unknown-linux-gnu, will push
to trunk since it eases debugging.

Richard.

2020-01-30  Richard Biener  <rguent...@suse.de>

        * tree-pretty-print.c (dump_generic_node): Wrap VECTOR_CST
        and CONSTRUCTOR in _Literal (type) with TDF_GIMPLE.
---
 gcc/tree-pretty-print.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/gcc/tree-pretty-print.c b/gcc/tree-pretty-print.c
index fe2e62b31ba..7de8c7b0cb7 100644
--- a/gcc/tree-pretty-print.c
+++ b/gcc/tree-pretty-print.c
@@ -2078,6 +2078,12 @@ dump_generic_node (pretty_printer *pp, tree node, int 
spc, dump_flags_t flags,
     case VECTOR_CST:
       {
        unsigned i;
+       if (flags & TDF_GIMPLE)
+         {
+           pp_string (pp, "_Literal (");
+           dump_generic_node (pp, TREE_TYPE (node), spc, flags, false);
+           pp_string (pp, ") ");
+         }
        pp_string (pp, "{ ");
        unsigned HOST_WIDE_INT nunits;
        if (!VECTOR_CST_NELTS (node).is_constant (&nunits))
@@ -2315,6 +2321,12 @@ dump_generic_node (pretty_printer *pp, tree node, int 
spc, dump_flags_t flags,
        bool is_struct_init = false;
        bool is_array_init = false;
        widest_int curidx;
+       if (flags & TDF_GIMPLE)
+         {
+           pp_string (pp, "_Literal (");
+           dump_generic_node (pp, TREE_TYPE (node), spc, flags, false);
+           pp_string (pp, ") ");
+         }
        pp_left_brace (pp);
        if (TREE_CLOBBER_P (node))
          pp_string (pp, "CLOBBER");
-- 
2.16.4

Reply via email to