coverage.c: Include tree-pass.h.
authorAdam Nemet <nemet@gcc.gnu.org>
Mon, 21 Apr 2008 23:35:47 +0000 (23:35 +0000)
committerAdam Nemet <nemet@gcc.gnu.org>
Mon, 21 Apr 2008 23:35:47 +0000 (23:35 +0000)
* coverage.c: Include tree-pass.h.
(coverage_counter_alloc): Print da_file_name to the dump file.

testsuite/
* gcc.dg/profile-dir-1.c, gcc.dg/profile-dir-2.c,
gcc.dg/profile-dir-3.c: Generate tree_profile dump.  Check gcda
file name there instead of the assembly.  Cleanup tree_profile
dump file.

From-SVN: r134541

gcc/ChangeLog
gcc/coverage.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/profile-dir-1.c
gcc/testsuite/gcc.dg/profile-dir-2.c
gcc/testsuite/gcc.dg/profile-dir-3.c

index 8b6363a613fbcfd54a03f78177d0b84e9294e888..e7fc5ef03e8b747d360db0be80209b85658a6dcc 100644 (file)
@@ -1,10 +1,15 @@
-2008-04-24  Kenneth Zadeck <zadeck@naturalbridge.com>
+2008-04-21  Adam Nemet  <anemet@caviumnetworks.com>
+
+       * coverage.c: Include tree-pass.h.
+       (coverage_counter_alloc): Print da_file_name to the dump file.
+
+2008-04-21  Kenneth Zadeck <zadeck@naturalbridge.com>
+
        * sbitmap.c (sbitmap_range_empty_p): New function.
        * sbitmap.h (sbitmap_range_empty_p): New function.
-       * bitmap.h: Now includes obstack.h.  
+       * bitmap.h: Now includes obstack.h.
 
-
-2008-04-24  Richard Sandiford  <rsandifo@nildram.co.uk>
+2008-04-21  Richard Sandiford  <rsandifo@nildram.co.uk>
            Kenneth Zadeck <zadeck@naturalbridge.com>
 
        * dbgcnt.def (ra_byte_scan): Added.
@@ -73,7 +78,6 @@
        (rtl_opt_pass pass_fast_rtl_byte_dce): New pass.
        * Makefile.in (df-byte-scan.o, debugcnt.o): Added dependencies.
 
-
 2008-04-21  Daniel Franke  <franke.daniel@gmail.com>
 
        PR fortran/35019
index cd1c13e2d5702a69d2564970c441ab5118950b1a..ec8d589539fdd97f590450d12c5756acf45d0857 100644 (file)
@@ -43,6 +43,7 @@ along with GCC; see the file COPYING3.  If not see
 #include "hashtab.h"
 #include "tree-iterator.h"
 #include "cgraph.h"
+#include "tree-pass.h"
 
 #include "gcov-io.c"
 
@@ -421,6 +422,9 @@ coverage_counter_alloc (unsigned counter, unsigned num)
       ASM_GENERATE_INTERNAL_LABEL (buf, "LPBX", counter + 1);
       DECL_NAME (tree_ctr_tables[counter]) = get_identifier (buf);
       DECL_ALIGN (tree_ctr_tables[counter]) = TYPE_ALIGN (gcov_type_node);
+
+      if (dump_file)
+       fprintf (dump_file, "Using data file %s\n", da_file_name);
     }
   fn_b_ctrs[counter] = fn_n_ctrs[counter];
   fn_n_ctrs[counter] += num;
index 37f4826bb22c64e96f76eb0da5d1978f45a5bc8f..4a86a03acafcab44fc2b0ad17d423dcc5adfc53c 100644 (file)
@@ -1,3 +1,10 @@
+2008-04-21  Adam Nemet  <anemet@caviumnetworks.com>
+
+       * gcc.dg/profile-dir-1.c, gcc.dg/profile-dir-2.c,
+       gcc.dg/profile-dir-3.c: Generate tree_profile dump.  Check gcda
+       file name there instead of the assembly.  Cleanup tree_profile
+       dump file.
+
 2008-04-21  Steve Ellcey  <sje@cup.hp.com>
 
        * gcc.dg/vect/vect-vfa-slp.c: XFAIL if vect_no_align.
index 78fbcb20eb500f076a7721c8b5b4b35e0da05953..a0a22ffb0b0a8c78c04d73ff906402e1806ea767 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
-/* { dg-options "-O -fprofile-generate=." } */
-/* { dg-final { scan-assembler "\"./profile-dir-1.gcda\"" } } */
+/* { dg-options "-O -fprofile-generate=. -fdump-tree-tree_profile" } */
+/* { dg-final { scan-tree-dump " ./profile-dir-1.gcda" "tree_profile" } } */
 
 int
 main(void)
@@ -9,3 +9,4 @@ main(void)
 }
 
 /* { dg-final { cleanup-coverage-files } } */
+/* { dg-final { cleanup-tree-dump "tree_profile" } } */
index af55b36a400d11199071333396f918857e7bf043..454f0641aa295e6d52b1f21b632385b125010a0e 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
-/* { dg-options "-O -fprofile-generate" } */
-/* { dg-final { scan-assembler "/profile-dir-2.gcda" } } */
+/* { dg-options "-O -fprofile-generate -fdump-tree-tree_profile" } */
+/* { dg-final { scan-tree-dump "/profile-dir-2.gcda" "tree_profile" } } */
 
 int
 main(void)
@@ -9,3 +9,4 @@ main(void)
 }
 
 /* { dg-final { cleanup-coverage-files } } */
+/* { dg-final { cleanup-tree-dump "tree_profile" } } */
index 0a924e97251b27d23e16b6ecc81c2933f6c3eac6..29b0a55871271b83011b588120bf9e3f07730f40 100644 (file)
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
-/* { dg-options "-O -fprofile-generate -fprofile-dir=." } */
-/* { dg-final { scan-assembler "\"./profile-dir-3.gcda\"" } } */
+/* { dg-options "-O -fprofile-generate -fprofile-dir=. -fdump-tree-tree_profile" } */
+/* { dg-final { scan-tree-dump " ./profile-dir-3.gcda" "tree_profile" } } */
 
 int
 main(void)
@@ -9,3 +9,4 @@ main(void)
 }
 
 /* { dg-final { cleanup-coverage-files } } */
+/* { dg-final { cleanup-tree-dump "tree_profile" } } */