PATCH: Fix 64-bit Solaris 2/x86 IE TLS code sequence

Jakub Jelinek jakub@redhat.com
Tue Mar 9 16:29:00 GMT 2010


On Tue, Mar 09, 2010 at 08:24:29AM -0800, H.J. Lu wrote:
> > Btw., in the meantime I've noticed that the code sequence demanded in
> > the Solaris Linker and Libraries Guide is not in any way Sun specific,
> > but actually still in the current version of the `ELF Handling for
> > Thread-Local Storage' specification:
> >
> >        http://people.redhat.com/drepper/tls.pdf
> >
> > So, unless there's an updated specification somewhere, the fix might be
> > applied more generally (which currently already happens; there's no
> > TARGET_SUN_TLS predicate anywhere), even though GNU ld can handle the
> > alternative code sequences produced by GCC just fine.

If Sun as/ld demands something, then penalizing Linux because of it is a bad
idea.  The GNU tls access sequences and their transitions are designed to
be quite flexible, if you force some particular insn unnecessarily just
because Sun as needs to have them, the generated code will be slower or
larger than needed on Linux.

	Jakub



More information about the Gcc-patches mailing list