linux-kbuild.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michal Marek <mmarek@suse.cz>
To: Andi Kleen <andi@firstfloor.org>
Cc: zippel@linux-m68k.org, linux-kbuild@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Improve kconfig symbol hashing
Date: Mon, 18 Jan 2010 13:21:54 +0100	[thread overview]
Message-ID: <4B545262.4020907@suse.cz> (raw)
In-Reply-To: <20100113160244.GA14012@basil.fritz.box>

On 13.1.2010 17:02, Andi Kleen wrote:
[...]
> This patch increases the hash table size to a larger prime
> and switches to a FNV32 hash. I played around with a couple of hash
> functions, but that one seemed to perform best with reasonable
> hash table sizes. 
> 
> Increasing the hash table size even further didn't
> seem like a good idea, because there are a couple of global
> walks which walk the complete hash table.
> 
> I also moved the unnamed bucket to 0. It's still the longest
> of all the buckets (44 entries), but hopefully it's not
> often hit except for the global walk which doesn't care.
> 
> The result is a much nicer distribution:
> (first column bucket length, second number of buckets with that length)
> 
> 1: 3505
> 2: 1236
> 3: 294
> 4: 52
> 5: 3
> 47: 1		<--- this is the unnamed symbols bucket
> 
> There are still some 5+ buckets, but increasing the hash table
> even more would be likely not worth it.
> 
> This also cleans up the code slightly by removing hard coded
> magic numbers.
> 
> I didn't notice a big performance difference either way 
> on my Nehalem system, but I presume it'll help somewhat
> on slower systems.
> 
> ---
>  scripts/kconfig/expr.h              |    5 ++---
>  scripts/kconfig/symbol.c            |   29 +++++++++++++++++------------
>  scripts/kconfig/zconf.tab.c_shipped |    2 +-
>  scripts/kconfig/zconf.y             |    2 +-
>  4 files changed, 21 insertions(+), 17 deletions(-)

Hi Andi,

The patch looks ok, but you forgot your Signed-off-by line?

Michal

  reply	other threads:[~2010-01-18 12:21 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-13 16:02 [PATCH] Improve kconfig symbol hashing Andi Kleen
2010-01-18 12:21 ` Michal Marek [this message]
2010-01-18 12:34   ` Andi Kleen
2010-01-18 12:36     ` Michal Marek

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=4B545262.4020907@suse.cz \
    --to=mmarek@suse.cz \
    --cc=andi@firstfloor.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=zippel@linux-m68k.org \
    /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 NNTP newsgroup(s).