need help w/ template & sdbout.c

Robert Lipe
Sun Sep 13 21:39:00 GMT 1998

I'm so confused.  I started trying to trace down why my target no longer
bootstraps and need some guidance.

If I set a breakpiont in sdbout.c here:

Breakpoint 5, sdbout_record_type_name (type=0x8315dd0)
    at ../../egcs/gcc/sdbout.c:487
487                 t = DECL_ASSEMBLER_NAME (TYPE_NAME (type));

it'll trigger quickly enough when I go to build stdexcepti.ii.  I think
(and I could be way off here) this is the code that's trying to do the
substitution of the mangled template name when emitting the debugging
records for COFF.   If I read things correctly, it then peers inside
the "assembler_name" member to get the mangled version but that doesn't 
seem to be mangled in this case.

 void allocator<_Tp>::deallocate(_Tp *, size_t) size_t allocator<_Tp>::max_size() const void allocator<_Tp>::construct(_Tp *, const _Tp &) void allocator<_Tp>::destroy(_Tp *)
Breakpoint 5, sdbout_record_type_name (type=0x8321190)
    at ../../egcs/gcc/sdbout.c:487
487                 t = DECL_ASSEMBLER_NAME (TYPE_NAME (type));
(gdb) print type->
$63 = 0x831a918 "rebind<_Tp1>"
(gdb) next
491           if (t != NULL_TREE)
492             name = IDENTIFIER_POINTER (t);
495       no_name = (name == 0 || *name == 0);
(gdb) print name
$64 = 0x831a918 "rebind<_Tp1>"

Can anyone offer hints as to whether I'm on the right trail or not?
Should the 'assembler_name' tree_node point to a tree_node of type
IDENTIFIER_NODE that contains an identifier.pointer to the unmangled
version?   If so, that should be done by pt.c, right?

This is my first foray into the guts of GCC, so any hints are 
appreciated.   The conversion of these accessor function macros
into actual C is not yet obvious to me.


More information about the Gcc mailing list