public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc(refs/vendors/ibm/heads/perf)] dump load permutations and refcount per SLP node
@ 2020-03-19  5:53 Jiu Fu Guo
  0 siblings, 0 replies; only message in thread
From: Jiu Fu Guo @ 2020-03-19  5:53 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:759bd406a2b900dd323571c3855a64f885e6b3b7

commit 759bd406a2b900dd323571c3855a64f885e6b3b7
Author: Richard Biener <rguenther@suse.de>
Date:   Wed Feb 26 14:51:26 2020 +0100

    dump load permutations and refcount per SLP node
    
    This adjusts dumping as proved useful in debugging.
    
    2020-02-26  Richard Biener  <rguenther@suse.de>
    
            * tree-vect-slp.c (vect_print_slp_tree): Also dump ref count
            and load permutation.

Diff:
---
 gcc/ChangeLog       |  5 +++++
 gcc/tree-vect-slp.c | 13 ++++++++++---
 2 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index c5b1eccb7d6..4b95966f171 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2020-02-26  Richard Biener  <rguenther@suse.de>
+
+	* tree-vect-slp.c (vect_print_slp_tree): Also dump ref count
+	and load permutation.
+
 2020-02-26  Richard Sandiford  <richard.sandiford@arm.com>
 
 	PR middle-end/93843
diff --git a/gcc/tree-vect-slp.c b/gcc/tree-vect-slp.c
index 077c7946fee..c7ddd94b39f 100644
--- a/gcc/tree-vect-slp.c
+++ b/gcc/tree-vect-slp.c
@@ -1641,7 +1641,7 @@ static void
 vect_print_slp_tree (dump_flags_t dump_kind, dump_location_t loc,
 		     slp_tree node, hash_set<slp_tree> &visited)
 {
-  unsigned i;
+  unsigned i, j;
   stmt_vec_info stmt_info;
   slp_tree child;
   tree op;
@@ -1651,13 +1651,13 @@ vect_print_slp_tree (dump_flags_t dump_kind, dump_location_t loc,
 
   dump_metadata_t metadata (dump_kind, loc.get_impl_location ());
   dump_user_location_t user_loc = loc.get_user_location ();
-  dump_printf_loc (metadata, user_loc, "node%s %p (max_nunits=%u)\n",
+  dump_printf_loc (metadata, user_loc, "node%s %p (max_nunits=%u, refcnt=%u)\n",
 		   SLP_TREE_DEF_TYPE (node) == vect_external_def
 		   ? " (external)"
 		   : (SLP_TREE_DEF_TYPE (node) == vect_constant_def
 		      ? " (constant)"
 		      : ""), node,
-		   estimated_poly_value (node->max_nunits));
+		   estimated_poly_value (node->max_nunits), node->refcnt);
   if (SLP_TREE_SCALAR_STMTS (node).exists ())
     FOR_EACH_VEC_ELT (SLP_TREE_SCALAR_STMTS (node), i, stmt_info)
       dump_printf_loc (metadata, user_loc, "\tstmt %u %G", i, stmt_info->stmt);
@@ -1669,6 +1669,13 @@ vect_print_slp_tree (dump_flags_t dump_kind, dump_location_t loc,
 		     i < SLP_TREE_SCALAR_OPS (node).length () - 1 ? "," : "");
       dump_printf (metadata, "}\n");
     }
+  if (SLP_TREE_LOAD_PERMUTATION (node).exists ())
+    {
+      dump_printf_loc (metadata, user_loc, "\tload permutation {");
+      FOR_EACH_VEC_ELT (SLP_TREE_LOAD_PERMUTATION (node), i, j)
+	dump_printf (dump_kind, " %u", j);
+      dump_printf (dump_kind, " }\n");
+    }
   if (SLP_TREE_CHILDREN (node).is_empty ())
     return;
   dump_printf_loc (metadata, user_loc, "\tchildren");


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-03-19  5:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-19  5:53 [gcc(refs/vendors/ibm/heads/perf)] dump load permutations and refcount per SLP node Jiu Fu Guo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).