From: Hui Zhu <teawater@gmail.com>
To: "Vellemans, Noel" <Noel.Vellemans@visionbms.com>
Cc: gdb@sourceware.org
Subject: Re: Q: GDB - Threads
Date: Tue, 26 May 2009 22:08:00 -0000 [thread overview]
Message-ID: <daef60380905261507i54e8f3b6q38c7c88a1d063fa0@mail.gmail.com> (raw)
In-Reply-To: <1531E53627F1F749B4FE809BF2A4EB67FABA56@WETMEX10.loepfe.com>
http://sourceware.org/gdb/current/onlinedocs/gdb_5.html#SEC28
http://sourceware.org/gdb/wiki/FAQ
GDB does not see any threads besides the one in which crash occurred;
or SIGTRAP kills my program when I set a breakpoint.
* This frequently happen on Linux, especially on embedded targets.
There are two common causes:
o
you are using glibc, and you have stripped libpthread.so.0
o
mismatch between libpthread.so.0 and libthread_db.so.1
GDB itself does not know how to decode "thread control blocks"
maintained by glibc and considered to be glibc private implementation
detail. It uses libhread_db.so.1 (part of glibc) to help it do so.
Therefore, libthread_db.so.1 and libpthread.so.0 must match in version
and compilation flags.
In addition, libthread_db.so.1 requires certain non-global
symbols to be present in libpthread.so.0.
Solution: use strip --strip-debug libpthread.so.0 instead of
strip libpthread.so.0.
On Wed, May 27, 2009 at 00:02, Vellemans, Noel
<Noel.Vellemans@visionbms.com> wrote:
>
> Hi,
>
> Somebody who can point me to a document (URL) that contains some info
> about GDB-(server)debugging with threads ?
>
> I'm having problems debugging multithread applications (compiled for
> ARM).
>
>
> Ref to : http://sourceware.org/ml/gdb/2009-05/msg00137.html
>
>
>
> GDB-6.8 (for ARM).
>
> /toolchain_build_arm/gdbhost-6.8/gdb$ ./gdb --v
> GNU gdb 6.8
> Copyright (C) 2008 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later
> <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law. Type "show
> copying"
> and "show warranty" for details.
> This GDB was configured as "--host=i386-pc-linux-gnu
> --target=arm-linux-uclibc".
>
>
>
>
>
>
>
>
> Kind Regards,
> Noel.
>
>
>
next prev parent reply other threads:[~2009-05-26 22:08 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-26 16:02 Vellemans, Noel
2009-05-26 22:08 ` Hui Zhu [this message]
2009-06-02 15:27 ` Vellemans, Noel
2009-06-02 16:41 ` Paul Pluzhnikov
2009-06-02 18:17 ` Daniel Jacobowitz
2009-06-02 18:34 ` Paul Pluzhnikov
2009-06-02 19:34 ` Daniel Jacobowitz
2009-06-03 15:21 ` Vellemans, Noel
2009-06-02 19:42 ` Paul Pluzhnikov
2009-06-03 3:17 ` Hui Zhu
2009-06-03 9:26 ` Vellemans, Noel
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=daef60380905261507i54e8f3b6q38c7c88a1d063fa0@mail.gmail.com \
--to=teawater@gmail.com \
--cc=Noel.Vellemans@visionbms.com \
--cc=gdb@sourceware.org \
/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