diff mbox

[GIMPLE,FE] Dump anon SSA names w/o identifier

Message ID alpine.LSU.2.11.1610271430110.5294@t29.fhfr.qr
State New
Headers show

Commit Message

Richard Biener Oct. 27, 2016, 12:30 p.m. UTC
The parser only groks those in declarations so make it easy and
emit them that way with -gimple.

Tested on x86_64-unknown-linux-gnu.

Richard.

2016-10-27  Richard Biener  <rguenther@suse.de>

	* tree-pretty-print.c (dump_generic_node): For -gimple dump
	anonymous SSA names without identifier.
diff mbox

Patch

diff --git a/gcc/tree-pretty-print.c b/gcc/tree-pretty-print.c
index 69c79d6..096eefd 100644
--- a/gcc/tree-pretty-print.c
+++ b/gcc/tree-pretty-print.c
@@ -2706,7 +2706,8 @@  dump_generic_node (pretty_printer *pp, tree node, int spc, int flags,
 	      && SSA_NAME_VAR (node)
 	      && DECL_NAMELESS (SSA_NAME_VAR (node)))
 	    dump_fancy_name (pp, SSA_NAME_IDENTIFIER (node));
-	  else
+	  else if (! (flags & TDF_GIMPLE)
+		   || SSA_NAME_VAR (node))
 	    dump_generic_node (pp, SSA_NAME_IDENTIFIER (node),
 			       spc, flags, false);
 	}