Skip to content

Commit 1776925

Browse files
authored
Merge pull request #719 from talex5/bench-info
Benchmarks: record uname, Eio backend, and number of cores
2 parents c53d897 + 94ab6cb commit 1776925

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

bench/main.ml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,19 @@ let () =
4545
"metrics", `List metrics;
4646
]
4747
in
48+
(* The benchmark machine runs an old Docker that blocks pidfd_open *)
49+
(* let uname = Eio.Process.parse_out env#process_mgr Eio.Buf_read.take_all ["uname"; "-a"] in *)
50+
let uname =
51+
let ch = Unix.open_process_in "uname -a" in
52+
let x = input_line ch in
53+
close_in ch;
54+
x
55+
in
4856
Fmt.pr "%a@." (Yojson.Safe.pretty_print ~std:true) @@ `Assoc [
57+
"config", `Assoc [
58+
"uname", `String uname;
59+
"backend", `String env#backend_id;
60+
"recommended_domain_count", `Int (Domain.recommended_domain_count ());
61+
];
4962
"results", `List (List.map run benchmarks);
5063
]

0 commit comments

Comments
 (0)