commit a57aac8a3edf245b1a36dc409272c619eed8231f
parent 6e7df990b3e1163f7ec7e2c4beb71b885bd07b1f
Author: William Casarin <jb55@jb55.com>
Date: Sat, 26 Aug 2023 16:39:53 -0700
fix benches
Diffstat:
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/bench-ingest-many.c b/bench-ingest-many.c
@@ -35,9 +35,9 @@ static int bench_parser()
char *json;
int times = 1;
- mapsize = 1024 * 1024 * 2000;
- ingester_threads = 10;
- assert(ndb_init(&ndb, mapsize, ingester_threads));
+ mapsize = 1024ULL * 1024ULL * 400ULL * 10ULL;
+ ingester_threads = 8;
+ assert(ndb_init(&ndb, "testdata/db", mapsize, ingester_threads));
const char *filename = "testdata/many-events.json";
if (!map_file(filename, (unsigned char**)&json, &written)) {
printf("mapping testdata/many-events.json failed\n");
diff --git a/bench-ingest.c b/bench-ingest.c
@@ -19,7 +19,7 @@ static int bench_parser(int times)
written = 0;
mapsize = 1024 * 1024 * 100;
ingester_threads = 8;
- assert(ndb_init(&ndb, mapsize, ingester_threads));
+ assert(ndb_init(&ndb, "testdata/db", mapsize, ingester_threads));
read_file("testdata/contacts-event.json", (unsigned char*)json, alloc_size, &written);
clock_gettime(CLOCK_MONOTONIC, &t1);