[David Mosberger <davidm@hpl.hp.com>] problem with unwind info for .init/.fini sections

Alan Modra amodra@bigpond.net.au
Fri Mar 1 21:34:00 GMT 2002


On Fri, Mar 01, 2002 at 05:00:10PM -0800, Richard Henderson wrote:
> On Fri, Mar 01, 2002 at 04:52:55PM -0800, David Mosberger wrote:
> > The reason I moved the labels outside is because
> > otherwise the linker seems to insist on creating the sections, even if
> > they're empty.  Is there another way to avoid this?
> 
> Not that I'm aware of.  I suppose you could put
> 
> 	${RELOCATING+. = ALIGN(${ALIGNMENT})}
> 
> before the first label, which should have the same effect.

Except when someone puts an .align <bignumber> in the segment in
question.  I might have a go at fixing PROVIDE one of these days.
It's a bit poor that PROVIDE (foo = something); inside a section
makes the section appear in the output when foo isn't referenced.
PROVIDE (foo = ABSOLUTE (something)); should similarly not cause
a section to be output by itself, even when foo _is_ referenced.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre



More information about the Binutils mailing list