From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29216 invoked by alias); 6 Oct 2010 22:43:59 -0000 Received: (qmail 29207 invoked by uid 22791); 6 Oct 2010 22:43:58 -0000 X-SWARE-Spam-Status: No, hits=-6.2 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 06 Oct 2010 22:43:52 +0000 Received: from int-mx08.intmail.prod.int.phx2.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o96MhYZV021743 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 6 Oct 2010 18:43:34 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx08.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o96MhYUM032630; Wed, 6 Oct 2010 18:43:35 -0400 Received: from opsy.redhat.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id o96MhXVe015585; Wed, 6 Oct 2010 18:43:33 -0400 Received: by opsy.redhat.com (Postfix, from userid 500) id E129D378893; Wed, 6 Oct 2010 16:43:32 -0600 (MDT) From: Tom Tromey To: Hilfinger@adacore.com Cc: gdb-patches@sourceware.org Subject: Re: [RFA] Extend hashed symbol dictionaries to work with Ada References: <201010050820.o958Kf42002588@syracuse.mckusick.com> Date: Wed, 06 Oct 2010 22:43:00 -0000 In-Reply-To: <201010050820.o958Kf42002588@syracuse.mckusick.com> (Paul Hilfinger's message of "Tue, 5 Oct 2010 01:20:41 -0700") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2010-10/txt/msg00094.txt.bz2 >>>>> "Paul" == Paul Hilfinger writes: Paul> This patch allows Ada to speed up symbol lookup by using the facilities Paul> in dictionary.[ch] for hashed lookups. Paul> Because this patch touches on a hashing algorithm used by other Paul> languages, I took the precaution of doing a speed test on a list of Paul> about 12000 identifiers (repeatedly inserting all of them into a table Paul> and then doing a lookup on a million names at random, thus testing the Paul> speed of the hashing algorithm and how well it distributed names). Thanks for looking at this. Paul> +full_match (const char* sym_name, const char* search_name) I noticed a few spots in the patch with "char* something" instead of "char *something". Paul> + case '$': case '.': case 'X': case '(': I personally think it is clearer to put each case on a separate line, but I don't insist on it. This is ok with the "char *" spacing thing fixed. Tom