This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[patch] testsuite: stale-infcall.exp: XFAIL also on mangled jmp_buf
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: gdb-patches at sourceware dot org
- Date: Tue, 3 Jul 2012 10:06:19 +0200
- Subject: [patch] testsuite: stale-infcall.exp: XFAIL also on mangled jmp_buf
Hi,
it FAILs instead of XFAILs on i386 systems without systemtap longjmp support.
There is i386_get_longjmp_target with valid tdep->jb_pc_offset so it tries to
figure out the destination address from jmp_buf which is mangled and it cannot
put breakpoint to the garbage address.
Contrary to it amd64_get_longjmp_target is not in effect as amd64-linux target
has tdep->jb_pc_offset == -1.
It would be best to detect jmp_buf is using mangled addresses but I do not
know how.
This is just a testsuite XFAIL so I will check it in.
Regards,
Jan
gdb/testsuite/
2012-07-03 Jan Kratochvil <jan.kratochvil@redhat.com>
Fix XFAIL compatibility with old i386 systems.
* gdb.base/stale-infcall.exp (test system longjmp tracking support):
Check also 'Cannot insert breakpoint 0'.
diff --git a/gdb/testsuite/gdb.base/stale-infcall.exp b/gdb/testsuite/gdb.base/stale-infcall.exp
index 9d73ebdb..0aa8c2a 100644
--- a/gdb/testsuite/gdb.base/stale-infcall.exp
+++ b/gdb/testsuite/gdb.base/stale-infcall.exp
@@ -33,7 +33,7 @@ gdb_test_multiple "next" $test {
-re " test-pass .*\r\n$gdb_prompt $" {
pass $test
}
- -re " test-fail .*\r\n$gdb_prompt $" {
+ -re "( test-fail .*|\r\nCannot insert breakpoint 0\\.\r\n.*)\r\n$gdb_prompt $" {
xfail $test
untested "System lacks support for tracking longjmps"
return -1