pid hash question

From: Borislav Deianov (borislav@lix.polytechnique.fr)
Date: Thu Mar 16 2000 - 18:21:15 EST


Hi,

The pid hash function in include/linux/sched.h looks like this:

#define pid_hashfn(x) ((((x) >> 8) ^ (x)) & (PIDHASH_SZ - 1))

What is the point of the >> 8 ? Since pids are assigned linearly (more
or less), wouldn't ((x) & (PIDHASH_SZ - 1)) be just as good?

Thanks,
Borislav

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



This archive was generated by hypermail 2b29 : Thu Mar 23 2000 - 21:00:22 EST