This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH] Put .gnu.linkonce.d.rel.ro.* sections into .data.rel.ro output section
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: binutils at sources dot redhat dot com, Ulrich Drepper <drepper at redhat dot com>
- Date: Thu, 15 Dec 2005 01:03:29 +1030
- Subject: Re: [PATCH] Put .gnu.linkonce.d.rel.ro.* sections into .data.rel.ro output section
- References: <20051214140950.GC4625@sunsite.mff.cuni.cz>
On Wed, Dec 14, 2005 at 03:09:50PM +0100, Jakub Jelinek wrote:
> --- ld/scripttempl/elf.sc.jj 2005-12-14 13:50:35.000000000 +0100
> +++ ld/scripttempl/elf.sc 2005-12-14 13:56:15.000000000 +0100
> @@ -117,7 +117,7 @@ if test -z "$GOT"; then
> fi
> DYNAMIC=".dynamic ${RELOCATING-0} : { *(.dynamic) }"
> RODATA=".rodata ${RELOCATING-0} : { *(.rodata${RELOCATING+ .rodata.* .gnu.linkonce.r.*}) }"
> -DATARELRO=".data.rel.ro : { *(.data.rel.ro.local) *(.data.rel.ro*) }"
> +DATARELRO=".data.rel.ro : { *(.data.rel.ro.local) *(.gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro*) *(.gnu.linkonce.d.rel.ro.*) }"
Is there any good reason why all the .data.rel.ro.local input sections
must be first? I suspect it might be better to keep the ordering as
given in input files, for data locality. ie. use
DATARELRO=".data.rel.ro : { *(.data.rel.ro* .gnu.linkonce.d.rel.ro.*) }"
Otherwise the patch is OK.
--
Alan Modra
IBM OzLabs - Linux Technology Centre