Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* Demangling and searches
@ 2003-01-07 23:56 Paul Hilfinger
  2003-01-08  0:13 ` David Carlton
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Paul Hilfinger @ 2003-01-07 23:56 UTC (permalink / raw)
  To: Elena Zannoni, Adam Fedor, GDB Patches, Daniel Jacobowitz


For some time, I've been meaning to ask a basic question about GDB
search strategy: for language implementations that mangle their
identifiers, the standard procedure in GDB at the moment is to search
for the demangled identifier among the demangled identifiers of the
symbol table, and to speed this search up by precomputing and storing
the demangled symbol names.  Why?

We used to do that for Ada mode in GDB, but subsequently changed our
approach entirely.  For Ada, we MANGLE the symbol we're searching for
and then search among the MANGLED (i.e., raw, unmodified, warm-from-
the-executable) names.  We do very little demangling as a result, and
do not devote any storage to demangled names.  Of course, we do have
to demangle during the 'info XXX' symbol searches, but that is not a
common operation (at least for our customers), and therefore we saw
little to be gained by storing the demangled names.

Is there some unfortunate feature of C++ and ObjC mangling that
completely prevents our approach for those languages?  What was the
rationale behind the current strategy?

Thanks for the information.

Paul Hilfinger


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2003-01-09 21:51 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-01-07 23:56 Demangling and searches Paul Hilfinger
2003-01-08  0:13 ` David Carlton
2003-01-08  0:38   ` Daniel Berlin
2003-01-09  2:38   ` Paul Hilfinger
2003-01-09 21:51     ` David Carlton
2003-01-08  1:04 ` Daniel Jacobowitz
2003-01-08  1:39 ` Elena Zannoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox