Skip to content

Commit

Permalink
add upper bound check for tps_blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
absolute0kelvin committed Jan 17, 2025
1 parent 2300395 commit 34aa582
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions bench/src/bin/speed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,14 @@ fn main() {
);
}
let blocks_for_db_population = args.entry_count / args.ops_per_block;
if blocks_for_db_population < args.tps_blocks {
panic!(
"blocks_for_db_population ({}/{}={}) cannot be less than tps_blocks ({}). Please make entry_count larger",
args.entry_count, args.ops_per_block,
blocks_for_db_population, args.tps_blocks
);
}
println!("blocks_for_db_population: {}", blocks_for_db_population);

println!("Workload configuration:");
println!(
Expand Down

0 comments on commit 34aa582

Please sign in to comment.