This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

patch for Regressions from "[rfc] -gdwarf-3 and DW_OP_call_frame_cfa"


> Date: Fri, 12 Jun 2009 14:26:33 +0200
> From: Hans-Peter Nilsson <hp@axis.com>

> The testsuite bogusly produces e.g. -gdwarf-21 and -gdwarf-23
> making this patch cause numerous (as in 83) regressions.
> Obviously now made a bug, but I'm not sure of the intent of that
> part of the proc gcc-dg-debug-runtest (the 'foreach level {1 ""
> 3} {' loop); it looks as if it really was intended to produce
> those options.  Maybe it's even used in real code?  Mark is
> fingered by svn blame but it appears he just consolidated this
> code.

Looks like the following is what is now intended.  Still, I'm
not sure this is right, as there are testsuite regressions even
though the gcc.log says the options are handled right.  So, I
have to do a full regtest to see whether it's your patch or a
bug in the following patch that causes e.g.:

Executing on host: /tmp/hpautotest-gcc1/cris-elf/gccobj/gcc/xgcc -B/tmp/hpautotest-gcc1/cris-elf/gccobj/gcc/ /tmp/hpauto
test-gcc1/gcc/gcc/testsuite/gcc.dg/debug/debug-1.c  -gdwarf-2 -g1 -dA -S   -isystem /tmp/hpautotest-gcc1/cris-elf/gccobj
/cris-elf/./newlib/targ-include -isystem /tmp/hpautotest-gcc1/gcc/newlib/libc/include  -o debug-1.s    (timeout = 300)
PASS: gcc.dg/debug/debug-1.c -gdwarf-2 -g1 (test for excess errors)
FAIL: gcc.dg/debug/debug-1.c scan-assembler xyzzy

Anyway.

gcc/testsuite:
	* lib/gcc-dg.exp (gcc-dg-debug-runtest): Append debug-level as
	separate options instead of appending 1 "" and 3 to the
	debug-format option.

Index: gcc/testsuite/lib/gcc-dg.exp
===================================================================
--- gcc/testsuite/lib/gcc-dg.exp	(revision 148427)
+++ gcc/testsuite/lib/gcc-dg.exp	(working copy)
@@ -288,11 +288,11 @@
 	    if { ! [string match "*: target system does not support the * debug format*" \
 		    $comp_output] } {
 		remove-build-file "trivial.S"
-		foreach level {1 "" 3} {
-		    lappend DEBUG_TORTURE_OPTIONS [list "${type}${level}"]
+		foreach level {-g1 "" -g3} {
+		    lappend DEBUG_TORTURE_OPTIONS [concat "${type}" "${level}"]
 		    foreach opt $opt_opts {
 			lappend DEBUG_TORTURE_OPTIONS \
-				[list "${type}${level}" "$opt" ]
+				[concat "${type}" "${level}" "$opt" ]
 		    }
 		}
 	    }

brgds, H-P


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]