Is this a gcc, gdb or readelf bug?

Nick Clifton nickc@redhat.com
Wed Dec 22 12:28:00 GMT 2004


Hi H. J.

> I can't debug gcc 4.0 with gdb:
> 
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19124

Note - I have just committed a patch to readelf to make its output 
slightly more helpful when it encounters problems like this.

The 19124 bug is definitely a GCC problem - readelf is just reporting 
the facts, and as Andrew Pinkski has reported if you compile with 
-fno-var-tracking the problem goes away.

> When I used idb, I got
> 
> (idb) stop in tls_symbolic_operand
> 
> Info: Optimized variables show as <no value> when no location is
> allocated.
> [#1: stop in int tls_symbolic_operand(rtx, enum machine_mode)]
> (idb) r
> 
> Is that a gdb/readelf or gcc bug?

GDB not being able to debug GCC is a GDB problem.  (Or possibly a 
problem of the compiler than was used to compile the GCC being 
debugged).  Either way I am pretty sure that readelf is blameless in 
this situation.

Cheers
   Nick




More information about the Gcc mailing list