]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
dbgcnt.def (gimple_unroll): New.
authorRichard Biener <rguenther@suse.de>
Thu, 7 Nov 2019 07:36:39 +0000 (07:36 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Thu, 7 Nov 2019 07:36:39 +0000 (07:36 +0000)
2019-11-07  Richard Biener  <rguenther@suse.de>

* dbgcnt.def (gimple_unroll): New.
* tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Check
gimple_unroll debug counter before applying transform.
(try_peel_loop): Likewise.

From-SVN: r277907

gcc/ChangeLog
gcc/dbgcnt.def
gcc/tree-ssa-loop-ivcanon.c

index f5ef703927dd36c2db0629698d1694b3b265ab12..b6db832f9fe57e2fc6a1c740e7f1c01fe9683e8e 100644 (file)
@@ -1,3 +1,10 @@
+2019-11-07  Richard Biener  <rguenther@suse.de>
+
+       * dbgcnt.def (gimple_unroll): New.
+       * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Check
+       gimple_unroll debug counter before applying transform.
+       (try_peel_loop): Likewise.
+
 2019-11-07  Kwok Cheung Yeung  <kcy@codesourcery.com>
 
        * ira.c (setup_alloc_regs): Setup no_unit_alloc_regs for
index 7c9daafe35d1c9b5aa0df09cca6bf9ab23067d5f..9455506343e8c0b3fc8d3c39c6af307c43685591 100644 (file)
@@ -198,3 +198,4 @@ DEBUG_COUNTER (vect_slp)
 DEBUG_COUNTER (dom_unreachable_edges)
 DEBUG_COUNTER (match)
 DEBUG_COUNTER (store_merging)
+DEBUG_COUNTER (gimple_unroll)
index d38959c3aa2bc363e72ff1e0e4acb2d4b3356aba..c505f85f91a997a50b840c8d185eec0894fb1f66 100644 (file)
@@ -64,6 +64,7 @@ along with GCC; see the file COPYING3.  If not see
 #include "tree-cfgcleanup.h"
 #include "builtins.h"
 #include "tree-ssa-sccvn.h"
+#include "dbgcnt.h"
 
 /* Specifies types of loops that may be unrolled.  */
 
@@ -884,6 +885,9 @@ try_unroll_loop_completely (class loop *loop,
            }
        }
 
+      if (!dbg_cnt (gimple_unroll))
+       return false;
+
       initialize_original_copy_tables ();
       auto_sbitmap wont_exit (n_unroll + 1);
       if (exit && niter
@@ -1074,6 +1078,9 @@ try_peel_loop (class loop *loop,
       return false;
     }
 
+  if (!dbg_cnt (gimple_unroll))
+    return false;
+
   /* Duplicate possibly eliminating the exits.  */
   initialize_original_copy_tables ();
   auto_sbitmap wont_exit (npeel + 1);