From f885cf0630c3322cf00a9add64e6bf16bea663bc Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Thu, 27 Sep 2018 15:25:53 +0200 Subject: benchmark: output adjusted total time --- contrib/benchmark/collect.awk | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'contrib') diff --git a/contrib/benchmark/collect.awk b/contrib/benchmark/collect.awk index 46ec23d42..b88b3dc7d 100644 --- a/contrib/benchmark/collect.awk +++ b/contrib/benchmark/collect.awk @@ -51,6 +51,11 @@ function abs(v) { } max = url[$2][$4]["time_us_max"]; url[$2][$4]["time_us_max"] = (t/n > max ? t/n : max) + } else if ($1 == "op_baseline") { + # take average time for operations from baseline values with format: + # op_baseline time_avg_us + op_baseline[$2] = $4; + have_baseline = 1; } } @@ -95,4 +100,13 @@ END { print "op_baseline", x, "time_avg_us", avg(op[x]["time_us"], op[x]["count"]) > baseline_out } } + + if (have_baseline) { + for (x in op) { + total_ops_adjusted[x] = op_baseline[x] * op[x]["count"]; + } + for (x in op) { + print "total_ops_adjusted_ms", total_ops_adjusted[x]; + } + } } -- cgit v1.2.3