This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: phdrs for orphans
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: binutils at sources dot redhat dot com, Rusty Russell <rusty at rustcorp dot com dot au>
- Date: Mon, 9 Dec 2002 23:48:11 +1030
- Subject: Re: phdrs for orphans
- References: <20021209125233.GB29106@bubble.sa.bigpond.net.au>
On Mon, Dec 09, 2002 at 11:22:33PM +1030, Alan Modra wrote:
> In the case where a linker script specifies PHDRS, lang_record_phdrs
> chooses a program header segment rather poorly for orphan output
> sections, just tacking anything without an explicit phdr onto the last
> phdr. I reckon we'll do better by first trying to use the same phdr
> as the section that the orphan naturally groups with.
>
> * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Set
> orphan output section phdrs from "place->os" phdrs.
>
> I'll commit this in the morning, all being well, as sources.redhat.com
> doesn't seem to want to talk at the moment.
Hmm, but why is the output statement re-ordering done by place_orphan
not doing this for us automatically? Huh, looks like place_orphan is
re-ordering the wrong list! I'll revisit this tomorrow..
--
Alan Modra
IBM OzLabs - Linux Technology Centre