From: Pedro Alves <pedro@codesourcery.com>
To: luisgpm@linux.vnet.ibm.com
Cc: gdb-patches@sourceware.org
Subject: Re: MI testsuite fix
Date: Thu, 10 Apr 2008 22:10:00 -0000 [thread overview]
Message-ID: <200804102212.21028.pedro@codesourcery.com> (raw)
In-Reply-To: <1207859802.9173.15.camel@gargoyle>
A Thursday 10 April 2008 21:36:42, Luis Machado escreveu:
> There is an additional failure in the MI testsuite (PPC) when running in
> asynch mode, mi-simplerun.exp and mi2-simplerun.exp, which seems to be
> an output ordering issue as well.
>
> "Correct" output:
> 220-exec-continue^M
> 220^running^M
> (gdb) ^M
> Hello, World!callme^M
> callme^M
> 220*stopped,reason="exited-normally"^M
> (gdb) ^M
> PASS: gdb.mi/mi-simplerun.exp: continue to end
>
> "Incorrect" output:
> 220-exec-continue^M
> 220^running^M
> Hello, World!callme^M
> callme^M
> (gdb) ^M
> FAIL: gdb.mi/mi-simplerun.exp: continue to end (failed to resume)
>
> Correct and incorrect between "" because both ending results are valid.
>
> This is not fixed by your latest patch, Pedro. What do you think?
>
Ah, this is the one I had already analized here:
http://sourceware.org/ml/gdb-patches/2008-03/msg00293.html
The issue is that there is a race between gdb printing (gdb)
and the inferior starting to print too. In sync mode, you
don't see it, because ^running and (gdb) and output before
starting the target:
fputs_unfiltered ("^running\n", raw_stdout);
fputs_unfiltered ("(gdb) \n", raw_stdout);
I don't know if the protocol specifies when is it that
a frontend should expect that the inferior starts outputing
to the console. (gdb) should mean GDB is ready for input,
not that the inferior started, right? Maybe GDB should
wait for a *running notification instead of (GDB), but
even so, I'm not sure every target will emit it in
single-threaded programs. So, to me this looks like
a testsuite deficiency. Perhaps we should just put
a sleep (1) at the start of that test.
--
Pedro Alves
next prev parent reply other threads:[~2008-04-10 21:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-10 20:37 Pedro Alves
2008-04-10 21:42 ` Luis Machado
2008-04-10 22:10 ` Pedro Alves [this message]
2008-04-10 23:13 ` Pedro Alves
2008-04-14 18:27 ` Daniel Jacobowitz
2008-04-21 12:58 ` Pedro Alves
2008-04-21 14:04 ` Daniel Jacobowitz
2008-04-21 15:05 ` Pedro Alves
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200804102212.21028.pedro@codesourcery.com \
--to=pedro@codesourcery.com \
--cc=gdb-patches@sourceware.org \
--cc=luisgpm@linux.vnet.ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox