Commit d2627cb0 authored by Leif Walsh's avatar Leif Walsh Committed by Yoni Fogel

[t:5027] add operation_extra for serial inserts


git-svn-id: file:///svn/toku/tokudb@44382 c7de825b-a66e-492c-adef-691d508d4ae1
parent dd7e6a68
...@@ -27,9 +27,14 @@ stress_table(DB_ENV* env, DB** dbp, struct cli_args *cli_args) { ...@@ -27,9 +27,14 @@ stress_table(DB_ENV* env, DB** dbp, struct cli_args *cli_args) {
operation_t put_op = (cli_args->serial_insert operation_t put_op = (cli_args->serial_insert
? serial_put_op ? serial_put_op
: random_put_op_singledb); : random_put_op_singledb);
struct serial_put_extra spe[num_threads];
ZERO_ARRAY(spe);
for (int i = 0; i < num_threads; i++) { for (int i = 0; i < num_threads; i++) {
arg_init(&myargs[i], dbp, env, cli_args); arg_init(&myargs[i], dbp, env, cli_args);
myargs[i].operation = put_op; myargs[i].operation = put_op;
if (cli_args->serial_insert) {
myargs[i].operation_extra = spe[i];
}
} }
run_workers(myargs, num_threads, cli_args->time_of_test, false, cli_args); run_workers(myargs, num_threads, cli_args->time_of_test, false, cli_args);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment