From: Tom Tromey <tromey@redhat.com>
To: sami wagiaalla <swagiaal@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [patch 2/3] Template Lookup
Date: Wed, 18 Aug 2010 21:59:00 -0000 [thread overview]
Message-ID: <m3lj83a8gi.fsf@fleche.redhat.com> (raw)
In-Reply-To: <4C446F49.5070204@redhat.com> (sami wagiaalla's message of "Mon, 19 Jul 2010 11:29:13 -0400")
>>>>> "Sami" == sami wagiaalla <swagiaal@redhat.com> writes:
Sami> This patch corrects that by introducing a meta variable representing
Sami> the template into the scope of the template instance.
I think this idea seems reasonable.
Sami> +static void
Sami> +add_template_variable (struct symbol *symbol, struct pending **listhead,
Sami> + struct objfile *objfile)
This needs an introductory comment.
Sami> + int i;
Sami> +
Sami> + struct cleanup *all_cleanups = make_cleanup (null_cleanup, NULL);
Remove that blank line.
Sami> + make_cleanup(xfree, tmp);
Space before open paren. There are a few of these.
Sami> + /* Has a template symbol for this symbol been added already ? */
Sami> + for (iterator = *(listhead);
Sami> + iterator != NULL;
Sami> + iterator = iterator->next)
I think this means that adding template symbols is O(N^2).
A temporary hash table for recording this info would be better.
Tom
next prev parent reply other threads:[~2010-08-18 21:59 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-19 15:29 sami wagiaalla
2010-08-18 21:59 ` Tom Tromey [this message]
2010-08-26 19:18 ` sami wagiaalla
2010-09-23 18:43 ` [patch 2/4] " sami wagiaalla
2010-09-27 9:27 ` sami wagiaalla
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=m3lj83a8gi.fsf@fleche.redhat.com \
--to=tromey@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=swagiaal@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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).