This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[patch] fix for step-reverse.exp
- From: Michael Snyder <msnyder at vmware dot com>
- To: "gdb-patches at sourceware dot org" <gdb-patches at sourceware dot org>
- Cc: Hui Zhu <teawater at gmail dot com>
- Date: Tue, 14 Jul 2009 13:17:31 -0700
- Subject: [patch] fix for step-reverse.exp
Hui's amd64 patch was failing this test, because the test
neglects to allow for the possibility that the call instruction
is not the first instruction on the line.
Hui, try it now.
Michael
2009-07-14 Michael Snyder <msnyder@vmware.com>
* gdb.reverse/step-reverse.exp (stepi into function call):
Call instruction may not be first instruction in the line.
(reverse stepi from a function call): Used wrong line number.
Index: gdb.reverse/step-reverse.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.reverse/step-reverse.exp,v
retrieving revision 1.1
diff -u -p -r1.1 step-reverse.exp
--- gdb.reverse/step-reverse.exp 27 Jun 2009 18:49:20 -0000 1.1
+++ gdb.reverse/step-reverse.exp 14 Jul 2009 20:16:42 -0000
@@ -104,6 +104,10 @@ gdb_test_multiple "stepi" "$test_message
send_gdb "stepi\n"
exp_continue
}
+ -re "STEPI TEST.*$gdb_prompt $" {
+ send_gdb "stepi\n"
+ exp_continue
+ }
}
# stepi thru return of a function call
@@ -168,7 +172,7 @@ gdb_test_multiple "stepi" "$test_message
# stepi backward out of a function call
-set stepi_location [gdb_get_line_number "FINISH TEST" "$srcfile"]
+set stepi_location [gdb_get_line_number "STEPI TEST" "$srcfile"]
set test_message "reverse stepi from a function call"
gdb_test_multiple "stepi" "$test_message" {
-re "ARRIVED IN CALLEE.*$gdb_prompt $" {
@@ -178,7 +182,7 @@ gdb_test_multiple "stepi" "$test_message
send_gdb "stepi\n"
exp_continue
}
- -re "${hex}\[ \t\]*$stepi_location.*STEPI TEST.*$gdb_prompt $" {
+ -re "${hex} in main .*:$stepi_location.*STEPI TEST.*$gdb_prompt $" {
send_gdb "stepi\n"
exp_continue
}