From: Daniel Jacobowitz <drow@false.org>
To: jbbachky@aim.com
Cc: gdb@sources.redhat.com
Subject: Re: gdb-6.6, faking a shared library
Date: Wed, 29 Nov 2006 15:46:00 -0000 [thread overview]
Message-ID: <20061129154650.GA2198@nevyn.them.org> (raw)
In-Reply-To: <8C8E1E45640370E-D40-84C5@MBLK-D29.sysops.aol.com>
On Wed, Nov 29, 2006 at 10:44:06AM -0500, jbbachky@aim.com wrote:
> What I'm calling a shared library is a subset of glibc which gets
> linked/mapped to a specific address, and the programs which "link
> against it" really link against fixed addresses, thus no dynamic
> linking is involved. Special startup code is used to map the library's
> addresses for each process which need it. However, since gdb knows
> nothing about it being shared among other processes (not simply other
> pthreads sharing the same memory map), bad things happen when a
> breakpoint in that library is hit by another process.
It won't help you to tell GDB that it's a shared library; GDB inserts
breakpoints in shared libraries the same way it does anywhere else.
The debug agent is usually responsible for handling places which need
special breakpoint handling. I think you'd need the kernel to do
breakpoint insertion/removal at context switches in the case you've
described.
--
Daniel Jacobowitz
CodeSourcery
prev parent reply other threads:[~2006-11-29 15:46 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-29 15:44 jbbachky
2006-11-29 15:46 ` Daniel Jacobowitz [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=20061129154650.GA2198@nevyn.them.org \
--to=drow@false.org \
--cc=gdb@sources.redhat.com \
--cc=jbbachky@aim.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