This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: PATCH: Fix ld bootstrap test for ia64
- To: "H . J . Lu" <hjl at lucon dot org>
- Subject: Re: PATCH: Fix ld bootstrap test for ia64
- From: Jim Wilson <wilson at cygnus dot com>
- Date: Tue, 02 Oct 2001 19:13:14 -0700
- cc: binutils at sources dot redhat dot com
># .../configure --enable-64-bit-bfd --enable-targets=all
I reproduced the problem with this configure command.
It didn't seem right to me that we still have this problem, so I investigated.
Some symbols are getting different gp offsets. These entries are in a
bfd_hash_table, and offsets are assigned in order via a simple bfd hash table
traverse, so that implies that the hash tables are different.
I tracked this down to get_dyn_sym_info in bfd/elfxx-ia64.c. This creates
some hash table entries at run time for which we have no symbol name, so
it synthesizes one using the abfd address and unique relocation info.
sprintf (addr_name, "%p:%lx", (void *) abfd, ELFNN_R_SYM (rel->r_info));
But the abfd address can vary if the linkers are not identical, and since
ld1 and ld2 are built differently, this causes the ld2 and ld3 linkers to be
different.
So we either need to build an ld4 in the testsuite, or else we need to use
a more deterministic method for creating fake symbol names here.
Jim