Re: [patch] arca-vm-2.2.5

Stephen C. Tweedie (sct@redhat.com)
Tue, 6 Apr 1999 22:22:28 +0100 (BST)


Hi,

On Tue, 6 Apr 1999 20:07:57 +0200 (CEST), Andrea Arcangeli
<andrea@e-mind.com> said:

> I was looking at the inode pointer part of the hash function and I think
> something like this should be better.

> -#define i (((unsigned long) inode)/(sizeof(struct inode) & ~ (sizeof(struct inode) - 1)))
> +#define i (((unsigned long) inode-PAGE_OFFSET)/(sizeof(struct inode) & ~ (sizeof(struct inode) - 1)))

This just ends up adding or subtracting a constant to the hash function,
so won't have any effect at all on the occupancy distribution of the
hash buckets.

--Stephen

-
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/