dbgcnt.def (dom_unreachable_edges): New debug counter.
authorJeff Law <law@redhat.com>
Tue, 22 Dec 2015 03:09:08 +0000 (20:09 -0700)
committerJeff Law <law@gcc.gnu.org>
Tue, 22 Dec 2015 03:09:08 +0000 (20:09 -0700)
* dbgcnt.def (dom_unreachable_edges): New debug counter.
* tree-ssa-dom.c: Include dbgcnt.h
(dom_opt_dom_walker::before_dom_children): Handle the new counter.

From-SVN: r231896

gcc/ChangeLog
gcc/dbgcnt.def
gcc/tree-ssa-dom.c

index f1f1d69a1d6e6cd88ed6630f89488fb364936f13..9e3ab5aaf92df2b0e6adf810881fa0e5993136f4 100644 (file)
@@ -1,3 +1,9 @@
+2015-12-21  Jeff Law  <law@redhat.com>
+
+       * dbgcnt.def (dom_unreachable_edges): New debug counter.
+       * tree-ssa-dom.c: Include dbgcnt.h
+       (dom_opt_dom_walker::before_dom_children): Handle the new counter.
+
 2015-12-21  Andrew Pinski <apinski@cavium.com>
 
        * config/aarch64/aarch64-option-extensions.def (LSE): Change
index 583b16b0f4fc95f52e1fd3ddcfa32d6e05035779..65f18fbfdf4582f11068f6ea2206bd84cee05e05 100644 (file)
@@ -192,3 +192,4 @@ DEBUG_COUNTER (treepre_insert)
 DEBUG_COUNTER (tree_sra)
 DEBUG_COUNTER (vect_loop)
 DEBUG_COUNTER (vect_slp)
+DEBUG_COUNTER (dom_unreachable_edges)
index 88fc517900c5653a6174c2ea4c31fb07b78e4d87..1b689a05126ebbbd45d485e6539e7e3059b8bc33 100644 (file)
@@ -44,6 +44,7 @@ along with GCC; see the file COPYING3.  If not see
 #include "tree-ssa-dom.h"
 #include "gimplify.h"
 #include "tree-cfgcleanup.h"
+#include "dbgcnt.h"
 
 /* This file implements optimizations on the dominator tree.  */
 
@@ -1369,6 +1370,9 @@ dom_opt_dom_walker::before_dom_children (basic_block bb)
   /* Now prepare to process dominated blocks.  */
   record_edge_info (bb);
   cprop_into_successor_phis (bb, m_const_and_copies);
+  if (taken_edge && !dbg_cnt (dom_unreachable_edges))
+    return NULL;
+
   return taken_edge;
 }