aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2008-04-08 22:26:01 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2008-04-08 22:26:01 +0000
commit2f9ea521e98580853eb89d4091e261834b4d666a (patch)
treeaafe0d642c5c8e78e15b005386d6fb74a19f3aa2 /gcc
parenta5e34caf3c36920fd52c0163914d0b2275c4ca0d (diff)
downloadgcc-2f9ea521e98580853eb89d4091e261834b4d666a.zip
gcc-2f9ea521e98580853eb89d4091e261834b4d666a.tar.gz
gcc-2f9ea521e98580853eb89d4091e261834b4d666a.tar.bz2
tree-cfg.c (verify_stmt): Print complete bogus stmt.
2008-04-09 Richard Guenther <rguenther@suse.de> * tree-cfg.c (verify_stmt): Print complete bogus stmt. (dump_function_to_file): Dump function arguments with types. * gfortran.dg/bind_c_usage_14.f03: Adjust. From-SVN: r134115
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/gfortran.dg/bind_c_usage_14.f0328
-rw-r--r--gcc/tree-cfg.c7
4 files changed, 30 insertions, 14 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 1151620..4118e9d 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2008-04-09 Richard Guenther <rguenther@suse.de>
+
+ * tree-cfg.c (verify_stmt): Print complete bogus stmt.
+ (dump_function_to_file): Dump function arguments with types.
+
2008-04-08 Richard Guenther <rguenther@suse.de>
* fold-const.c (fold_widened_comparison): Do not allow
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 33597e0..54c058e 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2008-04-09 Richard Guenther <rguenther@suse.de>
+
+ * gfortran.dg/bind_c_usage_14.f03: Adjust.
+
2008-04-08 Andy Hutchinson <hutchinsonandy@aim.com>
PR target/35005
diff --git a/gcc/testsuite/gfortran.dg/bind_c_usage_14.f03 b/gcc/testsuite/gfortran.dg/bind_c_usage_14.f03
index abcc46e..2d6726a 100644
--- a/gcc/testsuite/gfortran.dg/bind_c_usage_14.f03
+++ b/gcc/testsuite/gfortran.dg/bind_c_usage_14.f03
@@ -81,24 +81,24 @@ end subroutine sub6NoIso
! The subroutines (including entry) should have
! only a char-length parameter if they are not bind(C).
!
-! { dg-final { scan-tree-dump "sub1noiso .a, b, _a, _b\\)" "original" } }
-! { dg-final { scan-tree-dump "sub2 .a, b\\)" "original" } }
-! { dg-final { scan-tree-dump "sub3noiso .a, b, _a, _b\\)" "original" } }
-! { dg-final { scan-tree-dump "sub3noisoentry .x, y, z, _x, _z\\)" "original" } }
-! { dg-final { scan-tree-dump "sub4iso .a, b\\)" "original" } }
-! { dg-final { scan-tree-dump "sub4isoentry .x, y, z, _x, _z\\)" "original" } }
-! { dg-final { scan-tree-dump "sub5iso .a, b\\)" "original" } }
-! { dg-final { scan-tree-dump "sub5noisoentry .x, y, z, _x, _z\\)" "original" } }
-! { dg-final { scan-tree-dump "sub6noiso .a, b, _a, _b\\)" "original" } }
-! { dg-final { scan-tree-dump "sub6isoentry .x, y, z, _x, _z\\)" "original" } }
+! { dg-final { scan-tree-dump "sub1noiso \\(\[^.\]*a, \[^.\]*b, \[^.\]*_a, \[^.\]*_b\\)" "original" } }
+! { dg-final { scan-tree-dump "sub2 \\(\[^.\]*a, \[^.\]*b\\)" "original" } }
+! { dg-final { scan-tree-dump "sub3noiso \\(\[^.\]*a, \[^.\]*b, \[^.\]*_a, \[^.\]*_b\\)" "original" } }
+! { dg-final { scan-tree-dump "sub3noisoentry \\(\[^.\]*x, \[^.\]*y, \[^.\]*z, \[^.\]*_x, \[^.\]*_z\\)" "original" } }
+! { dg-final { scan-tree-dump "sub4iso \\(\[^.\]*a, \[^.\]*b\\)" "original" } }
+! { dg-final { scan-tree-dump "sub4isoentry \\(\[^.\]*x, \[^.\]*y, \[^.\]*z, \[^.\]*_x, \[^.\]*_z\\)" "original" } }
+! { dg-final { scan-tree-dump "sub5iso \\(\[^.\]*a, \[^.\]*b\\)" "original" } }
+! { dg-final { scan-tree-dump "sub5noisoentry \\(\[^.\]*x, \[^.\]*y, \[^.\]*z, \[^.\]*_x, \[^.\]*_z\\)" "original" } }
+! { dg-final { scan-tree-dump "sub6noiso \\(\[^.\]*a, \[^.\]*b, \[^.\]*_a, \[^.\]*_b\\)" "original" } }
+! { dg-final { scan-tree-dump "sub6isoentry \\(\[^.\]*x, \[^.\]*y, \[^.\]*z, \[^.\]*_x, \[^.\]*_z\\)" "original" } }
! The master functions should have always a length parameter
! to ensure sharing a parameter between bind(C) and non-bind(C) works
!
-! { dg-final { scan-tree-dump "master.0.sub3noiso .__entry, z, y, x, b, a, _z, _x, _b, _a\\)" "original" } }
-! { dg-final { scan-tree-dump "master.1.sub4iso .__entry, z, y, x, b, a, _z, _x, _b, _a\\)" "original" } }
-! { dg-final { scan-tree-dump "master.2.sub5iso .__entry, z, y, x, b, a, _z, _x, _b, _a\\)" "original" } }
-! { dg-final { scan-tree-dump "master.3.sub6noiso .__entry, z, y, x, b, a, _z, _x, _b, _a\\)" "original" } }
+! { dg-final { scan-tree-dump "master.0.sub3noiso \\(\[^.\]*__entry, \[^.\]*z, \[^.\]*y, \[^.\]*x, \[^.\]*b, \[^.\]*a, \[^.\]*_z, \[^.\]*_x, \[^.\]*_b, \[^.\]*_a\\)" "original" } }
+! { dg-final { scan-tree-dump "master.1.sub4iso \\(\[^.\]*__entry, \[^.\]*z, \[^.\]*y, \[^.\]*x, \[^.\]*b, \[^.\]*a, \[^.\]*_z, \[^.\]*_x, \[^.\]*_b, \[^.\]*_a\\)" "original" } }
+! { dg-final { scan-tree-dump "master.2.sub5iso \\(\[^.\]*__entry, \[^.\]*z, \[^.\]*y, \[^.\]*x, \[^.\]*b, \[^.\]*a, \[^.\]*_z, \[^.\]*_x, \[^.\]*_b, \[^.\]*_a\\)" "original" } }
+! { dg-final { scan-tree-dump "master.3.sub6noiso \\(\[^.\]*__entry, \[^.\]*z, \[^.\]*y, \[^.\]*x, \[^.\]*b, \[^.\]*a, \[^.\]*_z, \[^.\]*_x, \[^.\]*_b, \[^.\]*_a\\)" "original" } }
! Thus, the master functions need to be called with length arguments
! present
diff --git a/gcc/tree-cfg.c b/gcc/tree-cfg.c
index cf2001f..5cff71f 100644
--- a/gcc/tree-cfg.c
+++ b/gcc/tree-cfg.c
@@ -4181,6 +4181,11 @@ verify_stmt (tree stmt, bool last_in_block)
if (addr)
{
debug_generic_stmt (addr);
+ if (addr != stmt)
+ {
+ inform ("in statement");
+ debug_generic_stmt (stmt);
+ }
return true;
}
@@ -6130,6 +6135,8 @@ dump_function_to_file (tree fn, FILE *file, int flags)
arg = DECL_ARGUMENTS (fn);
while (arg)
{
+ print_generic_expr (file, TREE_TYPE (arg), dump_flags);
+ fprintf (file, " ");
print_generic_expr (file, arg, dump_flags);
if (TREE_CHAIN (arg))
fprintf (file, ", ");