From: Roland Puntaier <Roland.Puntaier@br-automation.com>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb@sources.redhat.com
Subject: Antwort: Re: relocations when doing file command at gdb prompt
Date: Thu, 08 Mar 2007 17:54:00 -0000 [thread overview]
Message-ID: <OF63BB2068.33A1CF17-ONC1257298.005B26E3-C1257298.00625A41@br-automation.com> (raw)
In-Reply-To: <20070308160501.GA8042@caradoc.them.org>
> Actually, ET_DYN is not quite either. It's more like a linked program
> for the purpose of my question.
Yes. Actually only the .plt .text and .data section find their way to the
target device.
> So, it's relocated already, but the relocations are still present.
> No wonder GDB is doubling them.
> ...
> I don't see how we can sensibly distinguish the two cases. What
> toolchain produced this file?
GCC, but with -Wl,-q,-shared,-T,"YYY.x", i.e shared and with modified
linker script, and the relocation info is kept because of a
post-processing using it.
This means there is no way to avoid the doubling and still keep the .rel
sections without changing GDB code, doesn't it?
Interesting that even
(gdb)add-symbol-file NewProgram.out 0 -s data 0
(gdb)info line 29
yields a wrong address.
In objfiles.c/objfile_relocate/(line 552) l->item[i].pc based on 0 would
be very fine, because ANOFFSET (objfile->section_offsets, i) (line 529)
turns out to be 0.
Strange that these two don't fit together.
next prev parent reply other threads:[~2007-03-08 17:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-07 16:16 Roland Puntaier
2007-03-08 15:22 ` Daniel Jacobowitz
2007-03-08 15:49 ` Roland Puntaier
2007-03-08 16:05 ` Daniel Jacobowitz
2007-03-08 17:54 ` Roland Puntaier [this message]
2007-03-08 18:26 ` Antwort: " Daniel Jacobowitz
2007-03-08 22:24 ` 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=OF63BB2068.33A1CF17-ONC1257298.005B26E3-C1257298.00625A41@br-automation.com \
--to=roland.puntaier@br-automation.com \
--cc=drow@false.org \
--cc=gdb@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