This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [GLIBC][AARCH64]Rewrite elf_machine_load_address using _DYNAMIC symbol
- From: Szabolcs Nagy <szabolcs dot nagy at arm dot com>
- To: Roland McGrath <roland at hack dot frob dot com>
- Cc: <nd at arm dot com>, Renlin Li <renlin dot li at foss dot arm dot com>, <libc-alpha at sourceware dot org>, Marcus Shawcroft <Marcus dot Shawcroft at arm dot com>, Richard Earnshaw <Richard dot Earnshaw at arm dot com>
- Date: Wed, 9 Nov 2016 14:48:21 +0000
- Subject: Re: [GLIBC][AARCH64]Rewrite elf_machine_load_address using _DYNAMIC symbol
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=none (sender IP is ) smtp.mailfrom=Szabolcs dot Nagy at arm dot com;
- Nodisclaimer: True
- References: <581C57FF.2090901@foss.arm.com> <20161104212440.A23F42C3AD8@topped-with-meat.com> <58209A8B.5030702@arm.com> <20161108212829.5ABE92C3A0D@topped-with-meat.com>
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
On 08/11/16 21:28, Roland McGrath wrote:
> Show me the code you have in mind using _DYNAMIC. The scheme using a
> linker-defined symbol with value 0 is the only one I'm aware of that
> reduces to the minimal number of assembly instructions, with none of them
> being a load.
well the current x86_64 code is already doing what i had in mind.
i assumed GOT[0] is used elsewhere so it has to be computed anyway
and then doing (_DYNAMIC-GOT[0]) should be the same as _BASE using
an extra sub.