summaryrefslogtreecommitdiffhomepage
path: root/examples/benchmark.c
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2020-11-02 12:24:32 +0100
committerTyge Løvset <[email protected]>2020-11-02 12:24:32 +0100
commit7171182ce7e0106f8f0fc47ed8f1fe1f58b2ea5d (patch)
tree6debbbe87d6b671ec32b1c97bca1c48cf9f1e986 /examples/benchmark.c
parent0737c3feea3b8015d6db9440b8221374363272c9 (diff)
downloadSTC-modified-7171182ce7e0106f8f0fc47ed8f1fe1f58b2ea5d.tar.gz
STC-modified-7171182ce7e0106f8f0fc47ed8f1fe1f58b2ea5d.zip
Changed (half)-internal *_INIT to *__init macros. Minor reformatting.
Diffstat (limited to 'examples/benchmark.c')
-rw-r--r--examples/benchmark.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/examples/benchmark.c b/examples/benchmark.c
index f831f417..419e7a8f 100644
--- a/examples/benchmark.c
+++ b/examples/benchmark.c
@@ -1,11 +1,10 @@
+#include <stdio.h>
+#include <time.h>
#include <stc/crandom.h>
#include <stc/cfmt.h>
#include <stc/cmap.h>
#include "others/khash.h"
-#include <stdio.h>
-#include <time.h>
-
#ifdef __cplusplus
#include <unordered_map>
#include "others/bytell_hash_map.hpp"
@@ -34,7 +33,7 @@ crand_rng64_t rng;
#define RAND(N) (crand_i64(&rng) & ((1 << N) - 1))
-#define CMAP_SETUP(X, Key, Value) cmap_##X map = cmap_INIT \
+#define CMAP_SETUP(X, Key, Value) cmap_##X map = cmap__init \
; cmap_##X##_set_load_factors(&map, max_load_factor, 0.0)
#define CMAP_PUT(X, key, val) cmap_##X##_put(&map, key, val).first->second
#define CMAP_EMPLACE(X, key, val) cmap_##X##_emplace(&map, key, val)