Skip to content

Commit

Permalink
Document the hash function used
Browse files Browse the repository at this point in the history
The hashing algorithm used for the hash table is
the jenkins one-at-a-time algorithm
  • Loading branch information
eivindjahren committed Oct 6, 2023
1 parent b51e7ba commit 9001e80
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/util/hash.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ extern "C" {
#define HASH_TYPE_ID 771065

/**
This is **THE** hash function - which actually does the hashing.
Implements the jenkins one-at-a-time hash function
see https://en.wikipedia.org/wiki/Jenkins_hash_function
*/

static uint32_t hash_index(const char *key, size_t len) {
Expand Down

0 comments on commit 9001e80

Please sign in to comment.