15 #undef CLIB_CUCKOO_TYPE 17 #define CLIB_CUCKOO_TYPE _8_8 18 #define CLIB_CUCKOO_KVP_PER_BUCKET (4) 19 #define CLIB_CUCKOO_LOG2_KVP_PER_BUCKET (2) 20 #define CLIB_CUCKOO_BFS_MAX_STEPS (2000) 21 #define CLIB_CUCKOO_BFS_MAX_PATH_LENGTH (8) 23 #ifndef __included_cuckoo_8_8_h__ 24 #define __included_cuckoo_8_8_h__ 33 #undef CLIB_CUCKOO_OPTIMIZE_PREFETCH 34 #undef CLIB_CUCKOO_OPTIMIZE_CMP_REDUCED_HASH 35 #undef CLIB_CUCKOO_OPTIMIZE_UNROLL 36 #undef CLIB_CUCKOO_OPTIMIZE_USE_COUNT_LIMITS_SEARCH 37 #define CLIB_CUCKOO_OPTIMIZE_PREFETCH 1 38 #define CLIB_CUCKOO_OPTIMIZE_CMP_REDUCED_HASH 1 39 #define CLIB_CUCKOO_OPTIMIZE_UNROLL 1 40 #define CLIB_CUCKOO_OPTIMIZE_USE_COUNT_LIMITS_SEARCH 1 42 #if __SSE4_2__ && !defined (__i386__) 43 #include <x86intrin.h> 59 if (v->
key == ~0ULL && v->
value == ~0ULL)
67 memset (v, 0xff,
sizeof (*v));
94 #if defined(clib_crc32c_uses_intrinsics) && !defined (__i386__) 95 return crc32_u64 (0, v->
key);
112 #undef __included_cuckoo_template_h__
Fixed length block allocator.
static u64 clib_xxhash(u64 key)
static int clib_cuckoo_key_compare_8_8(u64 a, u64 b)
Compare two clib_cuckoo_kv_8_8_t instances.
static u64 clib_cuckoo_hash_8_8(clib_cuckoo_kv_8_8_t *v)
8 octet key, 8 octet key value pair
static void clib_cuckoo_kv_set_free_8_8(clib_cuckoo_kv_8_8_t *v)
static int clib_cuckoo_kv_is_free_8_8(const clib_cuckoo_kv_8_8_t *v)
Decide if a clib_cuckoo_kv_8_8_t instance is free.
static u8 * format_cuckoo_kvp_8_8(u8 *s, va_list *args)
Format a clib_cuckoo_kv_8_8_t instance.