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: Another strike against ld -r


On Wed, Aug 11, 2004 at 09:22:18AM -0400, Daniel Jacobowitz wrote:
> Interesting... on i386 (binutils 2.15) I get:
> undef1.o(.text+0x2): In function `foo':
> /home/drow/tes/undef1.c:4: undefined reference to `bad1'
> undef2.o(.text+0x2): In function `bar':
> : undefined reference to `bad2'
> 
> vs
> 
> undef4.o(.text+0x2): In function `foo':
> /home/drow/tes/undef1.c:4: undefined reference to `bad1'
> undef4.o(.text+0x12): In function `bar':
> : undefined reference to `bad2'

I can see I probably should look into this further..  The difference
might be that the powerpc64 undefined reference is not in the .text
section.

> Do the line tables have the DW_LNE_end_of_sequence?  Were they
> generated with .loc manually by GCC?

Yes and yes.

> This isn't a strike against ld -r.  It's only a problem with ld -r for
> the linker's error messages...

Well, that's bad enough. :)

> it's just as much a problem with normal
> linking for, say, GDB.  The final executable won't be able to tell the
> difference between undef1's line numbers and the body of undef2 either,
> most likely.

True.

-- 
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]