From: Daniel Jacobowitz <drow@mvista.com>
To: Miles Bader <miles@gnu.org>
Cc: Andrew Cagney <ac131313@redhat.com>, gdb@sources.redhat.com
Subject: Re: gdbserver relocation?
Date: Tue, 04 Mar 2003 03:03:00 -0000 [thread overview]
Message-ID: <20030304030318.GB31172@nevyn.them.org> (raw)
In-Reply-To: <buoheaj3ly5.fsf@mcspd15.ucom.lsi.nec.co.jp>
On Tue, Mar 04, 2003 at 11:27:46AM +0900, Miles Bader wrote:
> Andrew Cagney <ac131313@redhat.com> writes:
> > I suspect you want to send something back using qOffsets.
>
> Yes, that's exactly what I needed.
>
> What do you think of the following patch (I added the `handle_query'
> target callback, and then provided a linux-low.c implementation)?
It looks reasonable to me. Do you have GDB copyright papers on file?
Content-Description: gdb-5.3-qoffsets-20030304.patch
> + if (errno == 0)
> + {
> + /* Both text and data offsets produced at compile-time (and so
> + used by gdb) are relative to the beginning of the program,
> + with the data segment immediately following the text segment.
> + However, the actual runtime layout in memory may put the data
> + somewhere else, so when we send gdb a data base-address, we
> + use the real data base address and subtract the compile-time
> + data base-address from it (which is just the length of the
> + text segment). BSS immediately follows data in both cases. */
Hmm, this only works if the executable is linked at 0 with data right
after text. Is that the case for all/most uClinux targets? I don't
know anything about uClinux.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
next prev parent reply other threads:[~2003-03-04 3:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-24 8:29 Miles Bader
2003-02-24 14:28 ` Daniel Jacobowitz
2003-02-24 15:26 ` Miles Bader
2003-02-24 15:43 ` Andrew Cagney
2003-03-04 2:28 ` Miles Bader
2003-03-04 3:03 ` Daniel Jacobowitz [this message]
2003-03-04 3:42 ` Miles Bader
2003-03-04 7:25 ` [uClinux-dev] " Greg Ungerer
2003-03-04 16:29 ` Andrew Cagney
2003-02-24 15:50 ` Daniel Jacobowitz
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=20030304030318.GB31172@nevyn.them.org \
--to=drow@mvista.com \
--cc=ac131313@redhat.com \
--cc=gdb@sources.redhat.com \
--cc=miles@gnu.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