From: Michael Snyder <msnyder@redhat.com>
To: Joel Brobecker <brobecker@gnat.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [RFA/testsuite] attach.exp: Add small delay in busy loop...
Date: Thu, 20 Nov 2003 20:20:00 -0000 [thread overview]
Message-ID: <3FBD21EF.5010600@redhat.com> (raw)
In-Reply-To: <20031120062549.GD504@gnat.com>
Joel Brobecker wrote:
> Hello,
>
> On Tue, Nov 18, 2003 at 04:26:07PM -0800, Michael Snyder wrote:
>
>>>2003-11-18 J. Brobecker <brobecker@gnat.com>
>>>
>>> * gdb.base/attach.c: Add small delay in busy loop.
>>> * gdb.base/attach.exp: Make some associated adjustments.
>>>
>>>OK to apply?
>>
>>Seems to work on Linux. I'd sure like to see that backtrace test,
>>though, to confirm that we are able to build a meaningful machine
>>state after we attach.
>
>
> Here is a new version of the patch, with the backtraces in. I do have
> two FAILs though. The first FAIL comes from the following test:
>
> gdb_test "backtrace" \
> ".*in nanosleep ().*in small_delay ().*in main ().*" \
> "backtrace after attach2"
>
> The logs show:
>
> backtrace
> #0 0x400eb3b5 in ?? () from /lib/libc.so.6
> #1 0x08048412 in small_delay () at ./gdb.base/attach.c:18
> #2 0x08048435 in main () at ./gdb.base/attach.c:29
> (gdb) FAIL: gdb.base/attach.exp: backtrace after attach2
>
> So the problem is that GDB is unable to find the function name for
> frame $0. I think this comes from these warnings while performing
> the attach command:
>
> attach 3671
> Attaching to process 3671
> Reading symbols from /[...]/testsuite/gdb.base/attach...done.
> --> Symbols already loaded for /lib/libm.so.6
> --> Symbols already loaded for /lib/libc.so.6
> Symbols already loaded for /lib/ld-linux.so.2
> 0x400eb3b5 in ?? () from /lib/libc.so.6^M
> (gdb) PASS: gdb.base/attach.exp: attach2
>
> The second FAIL is identical.
Probably should explicitly clear the symbol tables between
one attach and the next.
> There is another thing that I think needs mentioning. I noticed I am
> the first one to introduce the use of nanosleep(). I think it's pretty
> portable, but I am having doubts. Does anybody know if it's not available
> on any platform. How about cygwin for instance?
Yeah, I remember having issues with it when I tried to write
thread tests. I don't remember where it was missing -- maybe
Solaris? I think your concern is valid -- nanosleep is not
guaranteed to be available everywhere.
prev parent reply other threads:[~2003-11-20 20:20 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-18 23:00 Joel Brobecker
2003-11-19 0:26 ` Michael Snyder
2003-11-19 0:29 ` Daniel Jacobowitz
2003-11-19 19:16 ` Michael Snyder
2003-11-19 19:17 ` Daniel Jacobowitz
2003-11-20 6:25 ` Joel Brobecker
2003-11-20 20:20 ` Michael Snyder [this message]
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=3FBD21EF.5010600@redhat.com \
--to=msnyder@redhat.com \
--cc=brobecker@gnat.com \
--cc=gdb-patches@sources.redhat.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