2 Copyright (C) 1990, 2000, 2002 Free Software Foundation
3 written by Doug Lea <dl@rocky.oswego.edu>
9 Some useful hash function.
10 It's not a particularly good hash function (<< 5 would be better than << 4),
11 but people believe in it because it comes from Dragon book.
15 hashpjw (const unsigned char *x, unsigned int len) // From Dragon book, p436
20 for (; len > 0; len--)
23 if ((g = h & 0xf0000000) != 0)
24 h = (h ^ (g >> 24)) ^ g;