This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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]

Re: [resubmit] gdb.base, r*.exp thru w*.exp


Hi,

I get some strange issues with this series of commits. Some tests
start to randomly fail. It's quite hard to reproduce, I only have 1
out of ~10 boxes that exposes the issue in an random manner. To take a
real example, let's take this hunk:

On 20 May 2010 22:29, Michael Snyder <msnyder@vmware.com> wrote:
> Index: setshow.exp
> --- setshow.exp 5 May 2010 18:06:58 -0000 ? ? ? 1.14
> +++ setshow.exp 20 May 2010 20:24:11 -0000
> @@ -54,27 +54,25 @@ if { ![runto_main] } {
> ?#test set annotate 2
> -send_gdb "set annotate 2\n"
> -gdb_expect {
> - ? ? ? -re ".*\032\032pre-prompt.*$gdb_prompt .*\032\032prompt.*$" \
> - ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? { pass "set annotate 2" }
> - ? ? ? timeout ? ? ? ? ? ? ? ? { fail "(timeout) set annotate 2" }
> +
> +gdb_test_multiple "set annotate 2" "set annotate 2" {
> + ? ?-re ".*\032\032pre-prompt.*$gdb_prompt .*\032\032prompt.*$" {
> + ? ?pass "set annotate 2"
> ? ? }
> +}

Before that commit, the test seemed 100% reliable. After the commit,
if I run it in a loop on the affected box, I start to get failures
like that in my runs:

set annotate 2

^Z^Zpre-prompt
(gdb) FAIL: gdb.base/setshow.exp: set annotate 2

^Z^Zprompt

As you see the required things are in the output, but expect fails to
match it;. There must be some subtle difference between gdb_expect and
gdb_test_multiple when matching patterns containing prompts. Does that
make any sense to someone? Note that I took this precise example, but
I have a few places in the testsuite that show similar random
failures.

Thanks,
Fred


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