This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: elf backend hide_symbol bug
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: Hans-Peter Nilsson <hp at bitrange dot com>
- Cc: binutils at sources dot redhat dot com
- Date: Tue, 7 Sep 2004 11:37:15 +0930
- Subject: Re: elf backend hide_symbol bug
- References: <20040813083424.GH22977@bubble.modra.org> <Pine.BSF.4.58.0409062021270.83817@dair.pair.com>
On Mon, Sep 06, 2004 at 08:59:57PM -0400, Hans-Peter Nilsson wrote:
> On Fri, 13 Aug 2004, Alan Modra wrote:
>
> > See http://sources.redhat.com/bugzilla/show_bug.cgi?id=293 for my
> > analysis of this problem. mips, cris, xtensa maintainers should
> > note that there may be a similar problem for their ports.
>
> I think I need a clue here... Please bear with my denseness.
Please note the "may"! I didn't go so far as to convince myself that
cris really does have a problem. I just noted that in
elf_cris_adjust_gotplt_to_got, called from elf_cris_hide_symbol, you do
h->gotplt_refcount = -1
and in cris_elf_check_relocs, you
((struct elf_cris_link_hash_entry *) h)->gotplt_refcount++;
So, to tickle the bug on cris you need some combination of input files
that hides a symbol during the add_symbols phase of linking (visibility
or symbol versioning) and later references the same symbol using a
GOTPLT reloc.
--
Alan Modra
IBM OzLabs - Linux Technology Centre