Skip to content

Commit

Permalink
cyrudbbench: add twom support
Browse files Browse the repository at this point in the history
  • Loading branch information
brong committed Jan 10, 2025
1 parent e0d3d70 commit 60f0c61
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions bench/cyrdbbench.c
Original file line number Diff line number Diff line change
Expand Up @@ -368,12 +368,12 @@ static size_t do_write(int txnmode, int insmode)
return bytes;
}

static int parse_options(int argc, char **argv, const struct option *options)
static int parse_options(int argc, char **argv, const struct option *options __attribute__((unused)))
{
int option;
int option_index;

while ((option = getopt_long(argc, argv, "d:b:t:h?",
while ((option = getopt_long(argc, argv, "d:b:n:t:h?",
long_options, &option_index)) != -1) {
switch (option) {
case 'b':
Expand Down Expand Up @@ -481,11 +481,12 @@ int main(int argc, char *argv[])
}

if (strncmp(BACKEND, "twoskip", strlen("twoskip")) == 0 ||
strncmp(BACKEND, "twom", strlen("twom")) == 0 ||
strncmp(BACKEND, "zeroskip", strlen("zeroskip")) == 0) {
fprintf(stderr, "Running benchmarks for `%s` backend\n", BACKEND);
} else {
fprintf(stderr, "%s is not a valid CyrusDB backend. ", BACKEND);
fprintf(stderr, "Choose between `twoskip` or `zeroskip`.\n");
fprintf(stderr, "Choose between `twom`, `twoskip`, or `zeroskip`.\n");
ret = EXIT_FAILURE;
goto done;
}
Expand Down

0 comments on commit 60f0c61

Please sign in to comment.