Re: more on hash functions

Chuck Lever (cel@monkey.org)
Mon, 12 Apr 1999 21:10:22 -0400 (EDT)


On Mon, 12 Apr 1999, Paul F. Dietz wrote:
> Whoa! The size of the *random* tables is not related
> to the size of the *hash* table. Why should it be?
> The sizes of the random tables depend on the number of
> bits in each of the key fragments.

right, i understood that part. the range of the *values* in the random
tables, and not the range of the random table's *index*, is dependent on
the hash table size.

> As I said in the original message, the values stored
> in the random tables are in the range 0..PAGE_HASH_SIZE-1.
> If you've been picking only smaller values, no wonder the
> hash has been performing poorly!

well, i simply set the size of the hash table to be the same as the size
of the random tables. i think the only problem i caused myself was a
little inflexibility in hash table size, since the values in the
random tables were indeed random, and in the range 0...hash_table_size-1,
as you (and rivest et al.) prescribed.

- Chuck Lever

--
corporate:	<chuckl@netscape.com>
personal:	<chucklever@netscape.net> or <cel@monkey.org>

The Linux Scalability project: http://www.citi.umich.edu/projects/citi-netscape/

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/