This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: DWARF-2 and constructors/destructors
- From: Jason Merrill <jason at redhat dot com>
- To: gcc at gcc dot gnu dot org
- Cc: Daniel Berlin <dan at cgsoftware dot com>
- Date: Thu, 06 Dec 2001 18:16:53 +0000
- Subject: Re: DWARF-2 and constructors/destructors
- References: <20011205225246.A10961@nevyn.them.org>
>>>>> "Daniel" == Daniel Jacobowitz <dmj+@andrew.cmu.edu> writes:
> Suppose you want to call a (non-virtual) method in C++, from something
> with Dwarf-2 info. The only way to get the mangled name from the debug
> info is DW_AT_MIPS_linkage_name.
As Dan Berlin points out, The mangled name is already in the symbol table,
if there's actually a definition of the method. Why does it need to be in
the debug info as well? To call a non-virtual function, we're only
interested in its address. The debug information doesn't enter into it.
This applies to all functions, of course, not just ctors/dtors. The
DW_AT_MIPS_linkage_name stuff was a hack to make dwarf2 work with the
existing stabs-oriented code with minimal effort; it would save a lot of
space if we could get rid of it.
Jason