[lkml]   [2002]   [Sep]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: ip_conntrack_hash() problem
On Wed, Sep 04, 2002 at 11:24:25PM -0700, David S. Miller wrote:
> B) I despise the (1 << ...htable_bits) construct, used in several places.
> It's nothing but obfuscation. Please reinstate ...htable_size, and
> use that, the code will be more readable.
> You despise, but the processor doesn't. Less data loads
> means the code goes faster.

Please explain. I don't think that matters here:

Both _bits and _size are unsigned int, same amount of stuff to load.

The one single per-packet-path use is in hash_conntrack(), where
the _bits thing can be used without touching the _size thing.

All other places where the patch now uses _bits, really need _size,
and do the ugly computation by shifting. And all those other places
are called very rarely.

So, I don't see how your (abstractly true) observation is relevant, here.

best regards
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:28    [W:0.070 / U:0.416 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site