Motr  M0
Hash_fnc

Macros

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_LIB
 

Functions

static uint32_t swap_32 (uint32_t x)
 
static uint64_t swap_64 (uint64_t x)
 
static uint64_t fetch32 (const unsigned char *val)
 
static uint64_t fetch64 (const unsigned char *val)
 
static uint64_t rotate (uint64_t val, int shift)
 
static M0_UNUSED uint32_t rotate32 (uint32_t val, int shift)
 
M0_INTERNAL uint64_t m0_hash_fnc_fnv1 (const void *buffer, m0_bcount_t len)
 
static uint64_t hash_len16 (uint64_t u, uint64_t v, uint64_t mul)
 
static struct m0_uint128 weak_hash32_seeds_6 (uint64_t w, uint64_t x, uint64_t y, uint64_t z, uint64_t a, uint64_t b)
 
static struct m0_uint128 weak_hash32_seeds (const unsigned char *s, uint64_t a, uint64_t b)
 
static uint64_t shift_mix (uint64_t val)
 
static uint64_t hash_0to16 (const unsigned char *buffer, m0_bcount_t len)
 
static uint64_t hash_17to32 (const unsigned char *buffer, size_t len)
 
static uint64_t hash_33to64 (const unsigned char *buffer, size_t len)
 
M0_INTERNAL uint64_t m0_hash_fnc_city (const void *buffer, m0_bcount_t len)
 

Variables

static const uint64_t k0 = 0xc3a5c85c97cb3127ULL
 
static const uint64_t k1 = 0xb492b66fbe98f273ULL
 
static const uint64_t k2 = 0x9ae16a3b2f90404fULL
 
static const uint64_t def_mul = 0x9ddfea08eb382d69ULL
 

Detailed Description

Macro Definition Documentation

◆ M0_TRACE_SUBSYSTEM

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_LIB

Definition at line 28 of file hash_fnc.c.

Function Documentation

◆ fetch32()

static uint64_t fetch32 ( const unsigned char *  val)
inlinestatic

Definition at line 58 of file hash_fnc.c.

Here is the caller graph for this function:

◆ fetch64()

static uint64_t fetch64 ( const unsigned char *  val)
inlinestatic

Definition at line 66 of file hash_fnc.c.

Here is the caller graph for this function:

◆ hash_0to16()

static uint64_t hash_0to16 ( const unsigned char *  buffer,
m0_bcount_t  len 
)
static

Definition at line 139 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hash_17to32()

static uint64_t hash_17to32 ( const unsigned char *  buffer,
size_t  len 
)
static

Definition at line 170 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hash_33to64()

static uint64_t hash_33to64 ( const unsigned char *  buffer,
size_t  len 
)
static

Definition at line 182 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hash_len16()

static uint64_t hash_len16 ( uint64_t  u,
uint64_t  v,
uint64_t  mul 
)
inlinestatic

Definition at line 97 of file hash_fnc.c.

Here is the caller graph for this function:

◆ m0_hash_fnc_city()

M0_INTERNAL uint64_t m0_hash_fnc_city ( const void *  buffer,
m0_bcount_t  len 
)

Definition at line 205 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ m0_hash_fnc_fnv1()

M0_INTERNAL uint64_t m0_hash_fnc_fnv1 ( const void *  buffer,
m0_bcount_t  len 
)

Definition at line 84 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ rotate()

static uint64_t rotate ( uint64_t  val,
int  shift 
)
inlinestatic

Definition at line 74 of file hash_fnc.c.

Here is the caller graph for this function:

◆ rotate32()

static M0_UNUSED uint32_t rotate32 ( uint32_t  val,
int  shift 
)
inlinestatic

Definition at line 79 of file hash_fnc.c.

◆ shift_mix()

static uint64_t shift_mix ( uint64_t  val)
inlinestatic

Definition at line 134 of file hash_fnc.c.

Here is the caller graph for this function:

◆ swap_32()

static uint32_t swap_32 ( uint32_t  x)
inlinestatic

Definition at line 38 of file hash_fnc.c.

Here is the caller graph for this function:

◆ swap_64()

static uint64_t swap_64 ( uint64_t  x)
inlinestatic

Definition at line 45 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ weak_hash32_seeds()

static struct m0_uint128 weak_hash32_seeds ( const unsigned char *  s,
uint64_t  a,
uint64_t  b 
)
inlinestatic

Definition at line 124 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ weak_hash32_seeds_6()

static struct m0_uint128 weak_hash32_seeds_6 ( uint64_t  w,
uint64_t  x,
uint64_t  y,
uint64_t  z,
uint64_t  a,
uint64_t  b 
)
inlinestatic

Definition at line 109 of file hash_fnc.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ def_mul

const uint64_t def_mul = 0x9ddfea08eb382d69ULL
static

Definition at line 36 of file hash_fnc.c.

◆ k0

const uint64_t k0 = 0xc3a5c85c97cb3127ULL
static

Definition at line 33 of file hash_fnc.c.

◆ k1

const uint64_t k1 = 0xb492b66fbe98f273ULL
static

Definition at line 34 of file hash_fnc.c.

◆ k2

const uint64_t k2 = 0x9ae16a3b2f90404fULL
static

Definition at line 35 of file hash_fnc.c.