This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: binutils-2.19.90 snapshot is available
On Sat, Sep 12, 2009 at 12:41:59PM -0400, Christopher Faylor wrote:
> On Sat, Sep 12, 2009 at 04:26:26PM +0100, Dave Korn wrote:
> >Seems sane to me. It works by resetting the VMA after it's been used
> >in lang_size_sections_1 and the subsequent size calculations rather
> >than zeroing it out before these are done, yes?
>
> Yes. I tried to do the zero first and then do the size calculations
> using temporary values but couldn't get it quite right. I was afraid of
> impacting non-COFF too.
I'm curious to know what the difference was. ELF scripts set the
output section vma to zero (${RELOCATING-0}) for ld -r, and we also
set it to zero for orphans in lang_insert_orphan. If setting to zero
at the beginning didn't work, then you may have a problem with
orphans.
This:
if (link_info->relocatable)
os->addr_tree = exp_intop (0);
before the first use of addr_tree in lang_size_sections_1 ought to
good for all targets.
--
Alan Modra
Australia Development Lab, IBM