Subject: Re: CVS commit: syssrc/sys/miscfs/nullfs
To: Bill Studenmund <wrstuden@netbsd.org>
From: Jason R Thorpe <thorpej@wasabisystems.com>
List: source-changes
Date: 03/06/2002 14:10:57
On Wed, Mar 06, 2002 at 01:58:15PM -0800, Bill Studenmund wrote:

 > Not sure. Here's the code, followed by my thoughts on what it's doing:
 > 
 > #define LAYER_NHASH(lmp, vp) \
 >         (&((lmp)->layerm_node_hashtbl[(((u_long)vp)>>LOG2_SIZEVNODE) & \
 >                 (lmp)->layerm_node_hash]))

Yah, it's pretty much assuming those lower bits are always going to be
zero.

 > So is that the right thing to do with the pool allocator?

Probably not, but on the other hand, I think it would be a good idea
to instrument and experiment ... doing division would be bad, but picking
another shift value might do the trick.

-- 
        -- Jason R. Thorpe <thorpej@wasabisystems.com>