This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB 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: [PATCH] remove ECOFF


On Tue, 20 Aug 2013, Mark Kettenis wrote:

> > Maciej> The MIPS target wants to use minimal ECOFF debug information
> > Maciej> that is stored in ELF binaries in the so called PDR or Procedure
> > Maciej> Descriptor Record section [1].
> > 
> > Maciej>  Support for PDR unwinding (mips-mdebug-tdep.[ch]) was removed a
> > Maciej> while ago from GDB sources
> > 
> > Maciej>  I think this is a serious shortcoming of GDB on the MIPS target and a 
> > Maciej> good argument in favour to having this PDR unwinding support.
> > 
> > It's fine by me if you want to resurrect all the code.  I don't even
> > mind dropping my patch.
> > 
> > If you have a way to test the ECOFF code, then great.  I'd appreciate it
> > if you could volunteer to test whatever patches modify these readers.
> 
> I think Maciej concerns for MIPS pretty much mirror my concerns for
> Alpha.  I should be able to test stuff on Alpha, but not in the next
> three weeks.

 Following Stan's suggestion I had a look through mips-mdebug-tdep.[ch] we 
have and it seems to me its reliance on mdebugread.[ch] is minimal.  It 
imports the definition of `struct mdebug_extra_func_info' from 
mdebugread.h, but otherwise handles .pdr sections itself.  So it looks to 
me my concern may have been premature.

 I think moving the struct definition over to mips-mdebug-tdep.h shouldn't 
be a problem and the rest of ECOFF support can go then.  I'll see yet if 
all this PDR stuff builds and works with your patch applied.  I don't have 
a real ECOFF target to test with.

On Tue, 20 Aug 2013, Joseph S. Myers wrote:

> Rather than resurrecting this legacy MIPS-specific support, it would seem 
> a lot better on Linux to generate .eh_frame by default (as on various 
> other architectures) and phase out any remaining PDR generation there.  
> For glibc 2.18 the eh_frame CFI information is present in many assembly 
> sources and it could be added to the rest.

 That may be a long-term plan, however as I've noted, support for ECOFF 
function frame annotation in MIPS GAS has been there since forever and has 
been extensively documented in MIPS assembly manuals coming from various 
sources, and therefore is present in virtually all MIPS assembly code out 
there.  OTOH CFI information is mostly lacking from handcoded assembly 
sources.  Therefore while I think adding such CFI information will be 
valuable I also think there's value in having PDR unwinding handled as 
well.

 There are also the bare-iron targets whose users may not necessarily be 
happy to have extra .eh_frame data in their binaries.

 My understanding of the reason why mips-mdebug-tdep.[ch] were removed in 
the first place was the files had never been properly wired into the MIPS 
targets we keep supporting and their only users were obsoleted at one 
point, making mips-mdebug-tdep.[ch] orphan.

  Maciej


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]