]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
fold-const.c (debug_fold_checksum): Move it under ENABLE_FOLD_CHECKING.
authorAdam Nemet <anemet@caviumnetworks.com>
Thu, 21 Jun 2007 23:46:59 +0000 (23:46 +0000)
committerAdam Nemet <nemet@gcc.gnu.org>
Thu, 21 Jun 2007 23:46:59 +0000 (23:46 +0000)
* fold-const.c (debug_fold_checksum): Move it under
ENABLE_FOLD_CHECKING.

From-SVN: r125932

gcc/ChangeLog
gcc/fold-const.c

index bafa24edd1bf66616e408599478f84e2c98e8ac8..7ca7ae3ce25a67c496392833d3f873c49f25837c 100644 (file)
@@ -1,3 +1,8 @@
+2007-06-21  Adam Nemet  <anemet@caviumnetworks.com>
+
+       * fold-const.c (debug_fold_checksum): Move it under
+       ENABLE_FOLD_CHECKING.
+
 2007-06-21  Sebastian Pop  <sebpop@gmail.com>
 
        PR middle-end/20623
index c3b77d47e0c4a03cccce40ed057330ae3d035994..eaf637cc02cbf285a18916a05e1ed08c958344fb 100644 (file)
@@ -12943,6 +12943,30 @@ recursive_label:
     }
 }
 
+/* Helper function for outputting the checksum of a tree T.  When
+   debugging with gdb, you can "define mynext" to be "next" followed
+   by "call debug_fold_checksum (op0)", then just trace down till the
+   outputs differ.  */
+
+void
+debug_fold_checksum (tree t)
+{
+  int i;
+  unsigned char checksum[16];
+  struct md5_ctx ctx;
+  htab_t ht = htab_create (32, htab_hash_pointer, htab_eq_pointer, NULL);
+  
+  md5_init_ctx (&ctx);
+  fold_checksum_tree (t, &ctx, ht);
+  md5_finish_ctx (&ctx, checksum);
+  htab_empty (ht);
+
+  for (i = 0; i < 16; i++)
+    fprintf (stderr, "%d ", checksum[i]);
+
+  fprintf (stderr, "\n");
+}
+
 #endif
 
 /* Fold a unary tree expression with code CODE of type TYPE with an
@@ -12982,30 +13006,6 @@ fold_build1_stat (enum tree_code code, tree type, tree op0 MEM_STAT_DECL)
   return tem;
 }
 
-/* Helper function for outputting the checksum of a tree T.  When
-   debugging with gdb, you can "define mynext" to be "next" followed
-   by "call debug_fold_checksum (op0)", then just trace down till the
-   outputs differ.  */
-
-void
-debug_fold_checksum (tree t)
-{
-  int i;
-  unsigned char checksum[16];
-  struct md5_ctx ctx;
-  htab_t ht = htab_create (32, htab_hash_pointer, htab_eq_pointer, NULL);
-  
-  md5_init_ctx (&ctx);
-  fold_checksum_tree (t, &ctx, ht);
-  md5_finish_ctx (&ctx, checksum);
-  htab_empty (ht);
-
-  for (i = 0; i < 16; i++)
-    fprintf (stderr, "%d ", checksum[i]);
-
-  fprintf (stderr, "\n");
-}
-
 /* Fold a binary tree expression with code CODE of type TYPE with
    operands OP0 and OP1.  Return a folded expression if successful.
    Otherwise, return a tree expression with code CODE of type TYPE