diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 5f1ecdc7744..4830f69c312 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2003-12-17 Eric Botcazou + + * lib/gcc-dg.exp (gcc-dg-debug-runtest): Do not run debug-[12].c + at -O with stabs debugging formats. + * gcc.dg/debug/debug-1.c: Turn 'p' into a global variable. + * gcc.dg/debug/debug-2.c: Likewise. + 2003-12-16 Mark Mitchell PR c++/12696 diff --git a/gcc/testsuite/gcc.dg/debug/debug-1.c b/gcc/testsuite/gcc.dg/debug/debug-1.c index b413eb7223f..8cc520dcd79 100644 --- a/gcc/testsuite/gcc.dg/debug/debug-1.c +++ b/gcc/testsuite/gcc.dg/debug/debug-1.c @@ -3,7 +3,9 @@ /* { dg-options "-dA" } */ /* { dg-final { scan-assembler "xyzzy" } } */ -long foo(long p) +long p; + +long foo(void) { { long xyzzy = 0; diff --git a/gcc/testsuite/gcc.dg/debug/debug-2.c b/gcc/testsuite/gcc.dg/debug/debug-2.c index e11b7b0fc1f..b164ff97734 100644 --- a/gcc/testsuite/gcc.dg/debug/debug-2.c +++ b/gcc/testsuite/gcc.dg/debug/debug-2.c @@ -3,7 +3,9 @@ /* { dg-options "-dA" } */ /* { dg-final { scan-assembler "xyzzy" } } */ -long foo(long p) +long p; + +long foo(void) { if (1) { diff --git a/gcc/testsuite/lib/gcc-dg.exp b/gcc/testsuite/lib/gcc-dg.exp index 7fd52a94867..819e3ca5814 100644 --- a/gcc/testsuite/lib/gcc-dg.exp +++ b/gcc/testsuite/lib/gcc-dg.exp @@ -237,7 +237,7 @@ proc gcc-dg-debug-runtest { target_compile trivial opt_opts testcases } { # assembler output, but stabs debugging does not. # http://gcc.gnu.org/ml/gcc-regression/2003-04/msg00095.html if { [string match {*/debug-[12].c} "$nshort"] \ - && [string match "*O3*" "$flags"] \ + && [string match "*O*" "$flags"] \ && ( [string match "*coff*" "$flags"] \ || [string match "*stabs*" "$flags"] ) } { set doit 0