]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - gcc/postreload-gcse.c
Merge dataflow branch into mainline
[thirdparty/gcc.git] / gcc / postreload-gcse.c
index 3e3f805f1748846f5fcd9ce4c7ac487e983bbcb4..fdf5b04fc7864878efff2c62411ee2f31f34db2b 100644 (file)
@@ -1,5 +1,5 @@
 /* Post reload partially redundant load elimination
-   Copyright (C) 2004, 2005
+   Copyright (C) 2004, 2005, 2006, 2007
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -46,6 +46,7 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA
 #include "target.h"
 #include "timevar.h"
 #include "tree-pass.h"
+#include "dbgcnt.h"
 
 /* The following code implements gcse after reload, the purpose of this
    pass is to cleanup redundant loads generated by reload and other
@@ -1225,7 +1226,7 @@ delete_redundant_insns_1 (void **slot, void *data ATTRIBUTE_UNUSED)
 
   for (occr = expr->avail_occr; occr != NULL; occr = occr->next)
     {
-      if (occr->deleted_p)
+      if (occr->deleted_p && dbg_cnt (gcse2_delete))
        {
          delete_insn (occr->insn);
          stats.insns_deleted++;
@@ -1305,7 +1306,6 @@ rest_of_handle_gcse2 (void)
 {
   gcse_after_reload_main (get_insns ());
   rebuild_jump_labels (get_insns ());
-  delete_trivially_dead_insns (get_insns (), max_reg_num ());
   return 0;
 }