Skip to content

Commit 8637051

Browse files
committed
Added greater randomness in benchmark tests
1 parent 24d861c commit 8637051

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

bench/bench_atomic_skiplist.ml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ let write_heavy_workload () =
2525
(* A regular workload with 90% reads, 9% adds and 1% removes. *)
2626
let read_heavy_workload () =
2727
let sl = Atomicskiplist.create () in
28-
let elems = Array.init num_elems (fun _ -> Random.int 100) in
28+
let elems = Array.init num_elems (fun _ -> Random.int 10000) in
2929
let push = (fun () -> Domain.spawn ( fun () ->
3030
let start_time = Unix.gettimeofday () in
3131
for i = 0 to (num_elems - 1) do (
@@ -48,7 +48,7 @@ let read_heavy_workload () =
4848

4949
let moderate_heavy_workload () =
5050
let sl = Atomicskiplist.create () in
51-
let elems = Array.init num_elems (fun _ -> Random.int 100) in
51+
let elems = Array.init num_elems (fun _ -> Random.int 10000) in
5252
let push = (fun () -> Domain.spawn ( fun () ->
5353
let start_time = Unix.gettimeofday () in
5454
for i = 0 to (num_elems - 1) do (
@@ -70,7 +70,7 @@ let read_heavy_workload () =
7070

7171

7272

73-
let bench ~workload_type ~query_type () =
73+
let bench ~workload_type () =
7474
let workload =
7575
if workload_type = "read_heavy" then
7676
read_heavy_workload

0 commit comments

Comments
 (0)