This is the mail archive of the gdb@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: gdb 8.x - g++ 7.x compatibility


On Thu, 2018-02-08 at 11:26 +0000, Michael Matz wrote:
> As I said upthread, the mangled name of a type (sans _Z prefix) is what is 
> stored as the type name for RTTI purposes (i.e. std::type_info::name()).
> 
> It's just that the debug info currently doesn't have any reference to that 
> definitely-unique string, only to the "human-friendly" name, which 
> somewhat resembles the demangled name (and that's exactly the crux, it 
> really isn't the demangled one right now, as you found out the painful 
> way).

Isn't the problem with the mangled name, which otherwise would be just
what we wanted since it's easy to match and is unique in just the way
we want it to be, that mangling is not standardized?  If GDB relied on
the mangled name it would need to incorporate demanglers for any
compiler that it wanted to be able to debug and figure out which
demangler to use when it was trying to debug a program.  This goes
against the concept of a common debug format like DWARF I would expect.


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