On 18 May 2013, at 00:32, Benjamin Kaduk wrote: > > Consulting Knuth, it sounds like the state of the art is a pretty old > solution -- for a multiword/multicharacter key, u
There's actually been quite a lot of work done on hashing of arbitrary length binary objects. OpenAFS has an implementation of Bob Jenkin's "lookup3" hash in the opr library (the jhash.h header). There's also SpookyHash (also from Bob Jenkins), which is significantly faster than lookup3, but requires a 64bit processor, and Google's CityHash. Across the tree, I've been moving OpenAFS towards using jhash for hashing. However, there are some challenges about using this for ubik databases. In particular, the current code doesn't attempt to cater for endianness. I suspect you will get different answers for jhash2 on big and little endian processors. Fixing this shouldn't be that complex - the original lookup3.c code does the right thing, it's just a case of adapting that for OpenAFS. So, I'd encourage you towards doing that, rather than developing yet another hash algorithm. Cheers, Simon. _______________________________________________ OpenAFS-devel mailing list [email protected] https://lists.openafs.org/mailman/listinfo/openafs-devel
