public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Richard Earnshaw <rearnsha@arm.com>
To: Nathan Sidwell <nathan@codesourcery.com>
Cc: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [ARM] TLS Descriptor support
Date: Mon, 06 Jun 2011 16:27:00 -0000	[thread overview]
Message-ID: <4DECFFE4.4060308@arm.com> (raw)
In-Reply-To: <4DC8DFF6.4000600@codesourcery.com>

On 05/10/11 07:49, Nathan Sidwell wrote:
> This patch implements TLS descriptor support in GCC.  TLS descriptors 
> are described at 
> http://www.codesourcery.com/publications/RFC-TLSDESC-ARM.txt and 
> blessed by ARM, who have reserved the relocation numbers.
>
> Binutils and GLIBC patches are already committed (there is an 
> orthogonal glibc patch to do with make dependencies that I need to 
> post though).
>
> This patch adds a --with-tls={arm|gnu} configuration option, to 
> specify the default scheme.  It can be overridden with a 
> -mtls-dialect={arm|gnu} option (this is the name used by the x86 
> backend, which also has tlsdescriptor support).  I have not added 
> --with-tls support to the x86 bits of config.gcc etc, but it would be 
> simple to do so.
>
> The arm.{c,h,md} changes are fairly mechanical -- a new tls pattern 
> and smarts to emit it appropriately.
>
> This patch has been tested for both default arm and default gnu tls 
> schemes using the gcc and glibc testsuites for an arm-linux-gnueabi 
> target.
>
> ok?
>
> nathan
>
+    /* The + is to avoid an assembly parse ambiguity with symbols that
+       look like register names, which is unsuccessfully recovered 
from.  */
+    return TARGET_THUMB2 ? "blx\\t%c0(tlscall)" : "bl\\t+%c0(tlscall)";


Eh?  This is backwards.  There is blx <reg>, but no bl <reg>.  If the 
assembler gets confused with 'bl r0' then it needs to be fixed urgently.

Further, both the assembler and the linker know how to change bl to blx 
when needed, so it's best to just put out bl and be done with it.

R.



  parent reply	other threads:[~2011-06-06 16:27 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-10 11:23 Nathan Sidwell
2011-05-10 13:14 ` Joseph S. Myers
2011-05-11 15:43   ` Nathan Sidwell
2011-05-26  9:32 ` Nathan Sidwell
2011-05-27  4:43 ` Ramana Radhakrishnan
2011-05-31 13:03   ` Nathan Sidwell
2011-06-03 22:50     ` Ramana Radhakrishnan
2011-06-06  9:50       ` Nathan Sidwell
2011-06-06  9:54         ` Ramana Radhakrishnan
2011-06-06  9:56           ` Nathan Sidwell
2011-06-06 16:10             ` Ramana Radhakrishnan
2011-06-06 16:27 ` Richard Earnshaw [this message]
2011-06-07  6:11   ` Nathan Sidwell
2011-06-07 13:08     ` Richard Earnshaw
2011-06-21  8:42 ` Nathan Sidwell
2011-06-21 18:03   ` Ramana Radhakrishnan
2011-06-22 17:52     ` Nathan Sidwell

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=4DECFFE4.4060308@arm.com \
    --to=rearnsha@arm.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=nathan@codesourcery.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).