This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: stage one of gas reloc rewrite


On Sat, Aug 31, 2002 at 11:35:10AM -0400, Hans-Peter Nilsson wrote:
> I'm suspicious.  For most of the tests, you add local unnamed
> "*ABS*" symbols.  That doesn't seem right; I'd rather expect
> removal of local "*ABS*" symbols (or more removed than added).

I was waiting for this comment from you.  If you hadn't written such
a comprehensive testsuite, you'd never have noticed.  :-)

The symbol being added is the absolute section symbol.  You'll find
that in these cases it is in fact being used in relocs, so it's the
generally correct thing to do.  Note the comment at the end of
adjust_reloc_syms about BFD not handling relocs without symbols very
well.  The comment is right;  bfd_install_relocation will segfault
without a symbol.

That particular issue is really orthogonal to whether the symbol needs
to appear in the object file, but the comment used to say that COFF
support in BFD needed a symbol and I was worried that COFF needed a
symbol to be emitted.  In the case of ELF, I'll agree that the
absolute section symbol need not be emitted.  We can tidy that up
later.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]