Richard Guenther wrote: >> Hve you considered to just use DWARF and translate the DWARF debug >> info to a different format in LTRANS? For example, user wants stabs, >> LGEN generates DWARF, LTRANS reads in the DWARF, and dbxout is >> modified to translate the DWARF to stabs. > > +1
+2 This was my initial reaction to Cary's post as well. The nice thing about ELF/DWARF is that they are sufficient extensible to represent information needed for other formats. For example, when ARM designed its current ABI, the idea was that non-ELF object formats be handled by postprocessing the ELF output. I'd suggest the same thing here; make DWARF 3 the canonical internal format for debugging, and generate STABS, etc., by spitting that out from the encoded DWARF information. That doesn't mean of course that you have to literally use the DWARF file format as in-memory representation, any more than the current dwarf2out.c does; instead, you use an internal representation isomorphic to that. I'd imagine you could just start with the internal data structures dwarf2out.c already has. -- Mark Mitchell CodeSourcery m...@codesourcery.com (650) 331-3385 x713