This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: mi-break.exp intermitent failure
- From: Vladimir Prus <vladimir at codesourcery dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: Wed, 11 Jun 2008 17:38:56 +0400
- Subject: Re: mi-break.exp intermitent failure
- References: <200806111259.13949.pedro@codesourcery.com>
Pedro Alves wrote:
> Hi,
>
> I'm getting these intermitent FAILures in mi-break.exp (and a couple
> more in chain reaction) in sync mode, due to previous pattern
> considering the gdb prompt optional, hence sometimes consuming the
> *stopped line, and leaving the (gdb) unconsumed.
>
> Running ../../../src/gdb/testsuite/gdb.mi/mi-break.exp ...
> FAIL: gdb.mi/mi-break.exp: breakpoint at nonexistent function
> FAIL: gdb.mi/mi-break.exp: create varobj for function call
> FAIL: gdb.mi/mi-break.exp: update varobj for function call
Thanks for reporting; somehow I never run into this.
As I've told on IRC, the test should be using mi_expect_stop; I've no idea
why I did not covert it when I've introduced mi_expect_stop but I've
checked in the following patch. Can you check that no unexpected
failures happen for you now.
Incidentally, mi-async.exp is the only file that has direct checks for *stopped,
but those will die very soon now.
Thanks,
Volodya
Index: gdb/testsuite/ChangeLog
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/ChangeLog,v
retrieving revision 1.1661
diff -u -p -r1.1661 ChangeLog
--- gdb/testsuite/ChangeLog 10 Jun 2008 10:23:54 -0000 1.1661
+++ gdb/testsuite/ChangeLog 11 Jun 2008 13:34:48 -0000
@@ -1,5 +1,9 @@
2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
+ * gdb.mi/mi-break.exp (test_ignore_count): Use mi_expect_stop.
+
+2008-06-10 Vladimir Prus <vladimir@codesourcery.com>
+
* gdb.mi/mi-console.exp: Adjust.
* gdb.mi/mi-syn-frame.exp: Adjust.
* gdb.mi/mi2-console.exp: Adjust.
Index: gdb/testsuite/gdb.mi/mi-break.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.mi/mi-break.exp,v
retrieving revision 1.18
diff -u -p -r1.18 mi-break.exp
--- gdb/testsuite/gdb.mi/mi-break.exp 10 Jun 2008 09:35:08 -0000 1.18
+++ gdb/testsuite/gdb.mi/mi-break.exp 11 Jun 2008 13:34:48 -0000
@@ -158,17 +158,8 @@ proc test_ignore_count {} {
mi_run_cmd
- gdb_expect {
- -re ".*\\*stopped.*func=\"callme\".*args=\\\[\{name=\"i\",value=\"2\"\}\\\].*\r\n($mi_gdb_prompt)?$" {
- pass "run to breakpoint with ignore count"
- }
- -re ".*$mi_gdb_prompt$" {
- fail "run to breakpoint with ignore count"
- }
- timeout {
- fail "run to breakpoint with ignore count (timeout)"
- }
- }
+ mi_expect_stop "breakpoint-hit" "callme" "\{name=\"i\",value=\"2\"\}" ".*basics.c" "51" \
+ {"" "disp=\"keep\"" } "run to breakpoint with ignore count"
}
proc test_error {} {