[PATCH] .symver x, x@foo (take 2)

Alan Modra amodra@bigpond.net.au
Thu Feb 13 02:40:00 GMT 2003


On Tue, Feb 11, 2003 at 09:31:08AM +0100, Jakub Jelinek wrote:
> +	      (*bed->elf_backend_hide_symbol) (info, hi, TRUE);
> +	      hi->root.type = bfd_link_hash_indirect;
> +	      hi->root.u.i.link = (struct bfd_link_hash_entry *) h;
> +	      (*bed->elf_backend_copy_indirect_symbol) (bed, h, hi);
> +	      hi->elf_link_hash_flags = 0;

Why clear elf_link_hash_flags?

> +	      sym_hash = elf_sym_hashes (abfd);
> +	      if (sym_hash)
> +		for (symidx = 0; symidx < extsymcount; ++symidx)
> +		  if (sym_hash[symidx] == hi)
> +		    {
> +		      sym_hash[symidx] = h;
> +		      break;
> +		    }

I can't say I like this either.  Is it really necessary to tweak sym
hashes?  Won't later uses of the sym hash follow indirect links anyway?

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre



More information about the Binutils mailing list