On Wed, 2006-09-20 at 19:02 +0000, hjl at lucon dot org wrote:
> When reporting linker error, dwarf2 reader doesn't support more than one
> .debug_info section.

You can only have more than one debug_info section when
-feliminate-dwarf2-dups is used.  This isn't a commonly used option, and
there may be a number of problems with it.  This is allowed by DWARF3,
but not by DWARF2.

I see how your patch might help now.  The debug info is 32-bits as I
mentioned earlier.  The problem here is that pointers are 64-bits.
read_address uses addr_size, and hence is reading a 64-bit address when
it should be reading a 32-bit address, thus getting a number that is too
large.  Your fix adding 64-bit debug support helps because in the 32-bit
case you replaced the read_address call with a read_4_bytes call, which
correctly reads the 32-bit value we want.

However, this is speculation, as I don't know how to reproduce the
failure.  I don't understand why this hasn't come up before.  Also, it
isn't clear what this has to do with the further information you have
provided about multiple debug_info sections.
-- 
Jim Wilson, GNU Tools Support, http://www.specifix.com




_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to