From 796ae31ee71b36d22da4c5a85802756621a39137 Mon Sep 17 00:00:00 2001 From: Tim Beurskens Date: Wed, 16 Mar 2022 10:16:08 +0100 Subject: [PATCH] print benchmark status to stderr --- Cargo.lock | 2 +- Cargo.toml | 2 +- src/main.rs | 4 +++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 0a35b87..fe0a584 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -218,7 +218,7 @@ checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b" [[package]] name = "rsbdd" -version = "0.6.1" +version = "0.6.2" dependencies = [ "clap", "csv", diff --git a/Cargo.toml b/Cargo.toml index 1e00de4..4dd094e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rsbdd" -version = "0.6.1" +version = "0.6.2" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/src/main.rs b/src/main.rs index fb65fa5..5031434 100644 --- a/src/main.rs +++ b/src/main.rs @@ -66,10 +66,12 @@ fn main() { let mut exec_times = Vec::new(); // Benchmark: repeat n times and log runtime per iteration - for _ in 0..repeat { + for i in 0..repeat { let tick = Instant::now(); result = input_parsed.eval(); exec_times.push(tick.elapsed()); + + eprintln!("finished {}/{} runs", i + 1, repeat); } // only print performance results when the benchmark flag is available, and more than 1 run has completed