This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[commit] Handle valgrind failures more gracefully
- From: "Ulrich Weigand" <uweigand at de dot ibm dot com>
- To: gdb-patches at sourceware dot org
- Date: Sat, 12 Jun 2010 01:34:11 +0200 (CEST)
- Subject: [commit] Handle valgrind failures more gracefully
Hello,
I'm getting DejaGNU errors in gdb.base/valgrind-db-attach.exp
because my ppc64 valgrind refuses to start with an error:
valgrind: wrong ELF executable class (eg. 32-bit instead of 64-bit)
when runnning the testsuite in spu or ppc32 mode.
The following patch makes the test fail more gracefully as
simply UNSUPPORTED in such situations.
Tested on spu-elf, committed to mainline.
Bye,
Ulrich
ChangeLog:
* gdb.base/valgrind-db-attach.exp: Fail gracefully if valgrind
does not support ELF executable class.
Index: gdb/testsuite/gdb.base/valgrind-db-attach.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/valgrind-db-attach.exp,v
retrieving revision 1.4
diff -u -p -r1.4 valgrind-db-attach.exp
--- gdb/testsuite/gdb.base/valgrind-db-attach.exp 8 Jun 2010 22:58:03 -0000 1.4
+++ gdb/testsuite/gdb.base/valgrind-db-attach.exp 11 Jun 2010 23:23:34 -0000
@@ -51,6 +51,10 @@ gdb_test_multiple "" $test {
unsupported $test
return -1
}
+ -re "valgrind: wrong ELF executable class" {
+ unsupported $test
+ return -1
+ }
-re "command not found" {
# The spawn succeeded, but then valgrind was not found - e.g. if
# we spawned SSH to a remote system.
--
Dr. Ulrich Weigand
GNU Toolchain for Linux on System z and Cell BE
Ulrich.Weigand@de.ibm.com