This is the mail archive of the
mailing list for the glibc project.
Re: [RFC] _dl_tlsdesc_resolve_rela issue.
- From: Alexandre Oliva <aoliva at redhat dot com>
- To: OndÅej BÃlka <neleai at seznam dot cz>
- Cc: Andreas Schwab <schwab at linux-m68k dot org>, libc-alpha at sourceware dot org
- Date: Sun, 24 Nov 2013 09:17:35 -0200
- Subject: Re: [RFC] _dl_tlsdesc_resolve_rela issue.
- Authentication-results: sourceware.org; auth=none
- References: <20131018201318 dot GA7461 at domone dot podge> <87wqlal1f6 dot fsf at igel dot home> <20131018214224 dot GA8647 at domone dot podge>
On Oct 18, 2013, OndÅej BÃlka <firstname.lastname@example.org> wrote:
> There are two questions that I have to this file. First is why it saves
> r10, r11 but normal trampoline does not save these.
Normal trampolines only have to preserve registers used for argument
passing, while TLS resolvers have to preserve all registers.
> Second is why _dl_tlsdesc_resolve_hold uses
> jmp *(%eax)
This is a bug, likely the result of a cut&pasto from the i386 version on
which it was initially based. It should be %rax. Looks like we haven't
had very many cases of concurrent lazy relocation of the same TLS
descriptor in programs that get libc loaded outside the 32-bit address
range ;-) Thanks for catching this, and thanks in advance for fixing
it. The obvious patch is pre-approved.
Alexandre Oliva, freedom fighter http://FSFLA.org/~lxoliva/
You must be the change you wish to see in the world. -- Gandhi
Be Free! -- http://FSFLA.org/ FSF Latin America board member
Free Software Evangelist Red Hat Brazil Compiler Engineer