diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2024-10-04 14:29:00 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2024-10-04 14:29:00 +0200 |
| commit | 283effb16646112ee9c6bba57e021e80f322b29f (patch) | |
| tree | 3c0ad588e550f86df21687e82a17e9f1f60443be /src/solvers/h48/map.h | |
| parent | fc150adaf3bff133da0e59d842f13b7b21297fc0 (diff) | |
| download | nissy-core-283effb16646112ee9c6bba57e021e80f322b29f.tar.gz nissy-core-283effb16646112ee9c6bba57e021e80f322b29f.zip | |
Avoid repeating typedefs in tests
Diffstat (limited to 'src/solvers/h48/map.h')
| -rw-r--r-- | src/solvers/h48/map.h | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/src/solvers/h48/map.h b/src/solvers/h48/map.h index e74a5dd..e6903ce 100644 --- a/src/solvers/h48/map.h +++ b/src/solvers/h48/map.h | |||
| @@ -1,19 +1,5 @@ | |||
| 1 | #define MAP_UNSET UINT64_C(0xFFFFFFFFFFFFFFFF) | 1 | /* Type definitions and macros are in a separate file for easier testing */ |
| 2 | #define MAP_KEYMASK UINT64_C(0xFFFFFFFFFF) | 2 | #include "map_types_macros.h" |
| 3 | #define MAP_KEYSHIFT UINT64_C(40) | ||
| 4 | #define MAP_UNSET_VAL (MAP_UNSET >> MAP_KEYSHIFT) | ||
| 5 | |||
| 6 | typedef struct { | ||
| 7 | uint64_t n; | ||
| 8 | uint64_t capacity; | ||
| 9 | uint64_t randomizer; | ||
| 10 | uint64_t *table; | ||
| 11 | } h48map_t; | ||
| 12 | |||
| 13 | typedef struct { | ||
| 14 | uint64_t key; | ||
| 15 | uint64_t val; | ||
| 16 | } kvpair_t; | ||
| 17 | 3 | ||
| 18 | STATIC void h48map_create(h48map_t *, uint64_t, uint64_t); | 4 | STATIC void h48map_create(h48map_t *, uint64_t, uint64_t); |
| 19 | STATIC void h48map_clear(h48map_t *); | 5 | STATIC void h48map_clear(h48map_t *); |
