From: David Daney <ddaney@avtrex.com>
To: Daniel Jacobowitz <drow@false.org>
Cc: binutils@sourceware.org
Subject: Re: MIPS textrel fix
Date: Fri, 19 May 2006 09:03:00 -0000 [thread overview]
Message-ID: <446CEF9F.2070403@avtrex.com> (raw)
In-Reply-To: <20060518213149.GA14720@nevyn.them.org>
Daniel Jacobowitz wrote:
> While stuck offline earlier today, I revisited the textrel-1 MIPS
> failure. Eric originally tried setting DF_TEXTREL during section
> relocation, but it's too late: we add the entry in size_dynamic_sections.
> But I couldn't see any other way to get it right, since there's no
> hook to predict whether elf-eh-frame.c will eliminate a relocation.
>
> The easiest approach I found was to annul the DT_TEXTREL and DT_FLAGS
> changes in finish_dynamic_sections if no text relocations were
> actually generated. This is not immensely pretty, but does work.
> OK?
>
> For background, the problem arises from the use of absolute addresses
> in .eh_frame. In this case, they're being produced by gas CFI
> directives. Is there a reason we can't mix and match encodings?
> i.e. why not have gas use a PC-relative format? I'm sure there's
> a reason, but I can't think of it...
>
Could it be related to the reason that GCC no longer generates a
PC-relative .eh_frame?
I never fully understood the reason, but I think it has to do with
MIPS-ELF specifications not allowing the needed relocation types (even
though they work well in binutils/glibc/linux).
David Daney
next prev parent reply other threads:[~2006-05-18 22:05 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-05-19 0:37 Daniel Jacobowitz
2006-05-19 0:50 ` Daniel Jacobowitz
2006-05-19 6:09 ` Eric Christopher
2006-05-19 9:03 ` David Daney [this message]
2006-05-19 9:12 ` Thiemo Seufer
2006-05-19 9:26 ` David Daney
2006-05-19 10:18 ` Eric Christopher
2006-05-22 20:28 ` Daniel Jacobowitz
2006-05-22 20:28 ` Thiemo Seufer
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=446CEF9F.2070403@avtrex.com \
--to=ddaney@avtrex.com \
--cc=binutils@sourceware.org \
--cc=drow@false.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).