Advice on fixing gdb/12528

Paul Pluzhnikov ppluzhnikov@google.com
Fri Mar 11 17:09:00 GMT 2011


Greetings,

Doug and myself just independently hit
http://sourceware.org/bugzilla/show_bug.cgi?id=12528 (and 12568).

I would like advice on fixing it.

I know that in general GDB can not ignore code at location 0,
but it appears inevitable that it must do so on platforms where
- it is known that no code can execute there, and
- linker relocates debug info to address 0 to indicate that
  the corresponding code has been discarded.

So would something like:

 case DW_LNE_set_address:
   address = read_address (abfd, line_ptr, cu, &bytes_read);
   if (!target->to_valid_code_address (address)) {
      // this debug line info corresponds to function that has
      // been GCd by the linker.  Skip to end_sequence.
   }

in dwarf_decode_lines() ?

Thanks,
-- 
Paul Pluzhnikov



More information about the Gdb-patches mailing list