public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@false.org>
To: Christophe LYON <christophe.lyon@st.com>
Cc: binutils@sourceware.org
Subject: Re: Fix Thumb-2 shared libraries
Date: Wed, 26 Aug 2009 15:00:00 -0000	[thread overview]
Message-ID: <20090826143542.GA19943@caradoc.them.org> (raw)
In-Reply-To: <4A94F9FB.9070407@st.com>

On Wed, Aug 26, 2009 at 11:01:47AM +0200, Christophe LYON wrote:
> On 25.08.2009 20:51, Daniel Jacobowitz wrote:
>  > Unfortunately, this patch breaks Thumb-2 shared libraries.
> Would you mind giving an example?

Sure.  I built glibc as a Thumb-2 binary.  Because we change the type
of function symbols, calloc was marked as an ARM mode entry point in
ld.so's dynamic symbol table.  When ld.so resolves its own
relocations, it filled in an ARM-mode address in the PLT GOT.  So the
first call to calloc from ld.so caused us to execute Thumb code in ARM
mode.

> >Here's a patch I'm testing for this failure.
> It seems OK, but I think you forgot to add a test case :-)

I think your testcase serves nicely - now that I've fixed it to test
for correct behavior :-)

I'm going to wait for another internal test run before I commit this,
but it looks good so far.

-- 
Daniel Jacobowitz
CodeSourcery

  reply	other threads:[~2009-08-26 14:35 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-11 17:09 linker crash in arm stub generation Phil Blundell
2009-06-12 12:36 ` Nick Clifton
2009-06-12 13:19   ` Christophe LYON
2009-06-12 13:49     ` Nick Clifton
2009-06-12 14:06     ` Daniel Jacobowitz
2009-06-12 14:13       ` Christophe LYON
2009-06-15 14:22         ` Christophe LYON
2009-06-15 17:59           ` Daniel Jacobowitz
2009-06-17 15:44             ` Christophe LYON
2009-06-17 16:09               ` Phil Blundell
2009-06-17 18:10               ` Daniel Jacobowitz
2009-06-18 14:25                 ` Christophe LYON
2009-06-18 14:36                   ` Christophe LYON
2009-06-22  9:24                     ` Nick Clifton
2009-06-22 11:33                       ` Christophe LYON
2009-08-26  1:21                     ` Fix Thumb-2 shared libraries Daniel Jacobowitz
2009-08-26  3:11                       ` Daniel Jacobowitz
2009-09-09 18:36                         ` Daniel Jacobowitz
2009-09-14 12:30                           ` Daniel Jacobowitz
2009-08-26 10:39                       ` Christophe LYON
2009-08-26 15:00                         ` Daniel Jacobowitz [this message]
2009-08-26 17:24                           ` Christophe LYON

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=20090826143542.GA19943@caradoc.them.org \
    --to=drow@false.org \
    --cc=binutils@sourceware.org \
    --cc=christophe.lyon@st.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).