From: Daniel Jacobowitz <dan@codesourcery.com>
To: gdb@sourceware.org
Cc: Jan Kratochvil <jan.kratochvil@redhat.com>
Subject: PIE question
Date: Sun, 07 Mar 2010 00:53:00 -0000 [thread overview]
Message-ID: <20100307005326.GA29245@caradoc.them.org> (raw)
Jan, could you explain a little how the situation in this comment can
happen?
static void
svr4_relocate_main_executable (void)
{
CORE_ADDR displacement = svr4_exec_displacement ();
/* Even if DISPLACEMENT is 0 still try to relocate it as this is a new
difference of in-memory vs. in-file addresses and we could already
relocate the executable at this function to improper address before. */
I came across this because our local ARM uClinux incorrectly links in
solib-svr4.c. The remote target sends qOffsets, uses the result to
relocate the objfile, and then this code overrides that. I'll fix
the target. But if there was any circumstance where a solib-svr4.c
target could also send qOffsets (I think some KGDB ports do this?)
then this will undo it.
I don't think this is related to our other discussion about executable
relocation; I haven't forgotten, I'll get back to you as soon as I can.
--
Daniel Jacobowitz
CodeSourcery
next reply other threads:[~2010-03-07 0:53 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-07 0:53 Daniel Jacobowitz [this message]
2010-03-08 21:37 ` Jan Kratochvil
2010-03-08 21:58 ` Daniel Jacobowitz
2010-03-10 21:00 ` Jan Kratochvil
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=20100307005326.GA29245@caradoc.them.org \
--to=dan@codesourcery.com \
--cc=gdb@sourceware.org \
--cc=jan.kratochvil@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