Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Daniel Jacobowitz <drow@mvista.com>
To: Andrew Cagney <ac131313@redhat.com>
Cc: Will Cohen <wcohen@redhat.com>, gdb@sources.redhat.com
Subject: Re: Slow handling of C++ symbol names
Date: Fri, 21 Nov 2003 17:58:00 -0000	[thread overview]
Message-ID: <20031121175832.GA30361@nevyn.them.org> (raw)
In-Reply-To: <3FBCF1C9.5040106@redhat.com>

On Thu, Nov 20, 2003 at 11:54:33AM -0500, Andrew Cagney wrote:
> >
> >Well, I remember fixing some startup time issues since then :P  For
> >instance, the cache shared between minimal and partial symbols should
> >cut demangling time about in half.
> 
> Ah, this: symbol_set_names?  I was looking at the demangler.
> 
> >Which leads to the question.  Why does GDB demangle symbols?  My 
> >>simplistic understanding of the code is that GDB only needs the "iw" 
> >>(a.k.a., demangled string up to  but excluding the lparen and ignoring 
> >>white space) part of the symbol in the search table (the rest isn't so 
> >>critical and can be constructed on-demand).
> >
> >
> >A substantial amount of  demangling is needed to produce the part of
> >the symbol before the lparen; consider templates.  Also, we need the
> >full names in the minimal symbol for break 'foo(int)' with quotes to
> >work.  And there are assumptions of unique symbol names in our
> >hashing/searching, IIRC.
> 
> But without looking at the data we've no idea how substantial any 
> particular part really is.  For instance, when analysing the bcache 
> found that when debugging a C program every entry is 28 bytes in size!
> 
> 'foo(int)' can be broken down into "foo" "(int)" the latter only being 
> demanged and stored on-demand.

"They" tell me that the demangler did not support doing this.  But it
may soon.

Will, you may want to test a CVS snapshot from today or later.  The
demangler for GNU v3 was replaced last night; the new one appears to be
about twice as efficient.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


  parent reply	other threads:[~2003-11-21 17:58 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3FBBDC27.50204@redhat.com>
2003-11-19 21:13 ` Daniel Jacobowitz
2003-11-20 16:09   ` Andrew Cagney
2003-11-20 16:19     ` Daniel Jacobowitz
2003-11-20 16:54       ` Andrew Cagney
2003-11-20 16:58         ` Daniel Jacobowitz
2003-11-21 17:58         ` Daniel Jacobowitz [this message]
2003-11-26 14:27           ` Andrew Cagney
2003-11-26 16:24             ` Will Cohen
2003-11-26 20:48               ` Andrew Cagney
2003-11-26 20:45             ` Will Cohen
2003-12-02 22:09 Michael Elizabeth Chastain
2003-12-02 22:23 ` Ian Lance Taylor
2003-12-02 22:29   ` Daniel Jacobowitz
2003-12-03 18:52 ` Andrew Cagney
2003-12-02 22:38 Michael Elizabeth Chastain
2003-12-03 16:48 Michael Elizabeth Chastain
2003-12-03 16:52 ` David Carlton
2003-12-03 16:58 ` Ian Lance Taylor
2003-12-03 17:08   ` Daniel Jacobowitz
2003-12-03 17:34     ` Ian Lance Taylor
2003-12-03 17:38       ` Daniel Jacobowitz
2003-12-03 17:54         ` Ian Lance Taylor
2003-12-03 19:57 Michael Elizabeth Chastain
2003-12-03 20:16 ` Daniel Jacobowitz
2003-12-03 20:14 Michael Elizabeth Chastain
2003-12-03 20:17 Michael Elizabeth Chastain
2003-12-03 20:27 Michael Elizabeth Chastain
2003-12-03 20:35 ` Ian Lance Taylor
2003-12-03 22:30 Michael Elizabeth Chastain

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20031121175832.GA30361@nevyn.them.org \
    --to=drow@mvista.com \
    --cc=ac131313@redhat.com \
    --cc=gdb@sources.redhat.com \
    --cc=wcohen@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox