From 66349e3d23f3ec053639c44e167228b23f84a5c8 Mon Sep 17 00:00:00 2001 From: SChernykh Date: Wed, 23 Dec 2020 14:31:38 +0100 Subject: [PATCH] Show hashrate in the benchmark finished message --- src/base/net/stratum/benchmark/BenchClient.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/base/net/stratum/benchmark/BenchClient.cpp b/src/base/net/stratum/benchmark/BenchClient.cpp index beac2f19..c81f4010 100644 --- a/src/base/net/stratum/benchmark/BenchClient.cpp +++ b/src/base/net/stratum/benchmark/BenchClient.cpp @@ -126,7 +126,8 @@ void xmrig::BenchClient::onBenchDone(uint64_t result, uint64_t diff, uint64_t ts const uint64_t ref = referenceHash(); const char *color = ref ? ((result == ref) ? GREEN_BOLD_S : RED_BOLD_S) : BLACK_BOLD_S; - LOG_NOTICE("%s " WHITE_BOLD("benchmark finished in ") CYAN_BOLD("%.3f seconds") WHITE_BOLD_S " hash sum = " CLEAR "%s%016" PRIX64 CLEAR, tag(), static_cast(ts - m_readyTime) / 1000.0, color, result); + const double dt = static_cast(ts - m_readyTime) / 1000.0; + LOG_NOTICE("%s " WHITE_BOLD("benchmark finished in ") CYAN_BOLD("%.3f seconds (%.1f h/s)") WHITE_BOLD_S " hash sum = " CLEAR "%s%016" PRIX64 CLEAR, tag(), dt, BenchState::size() / dt, color, result); if (m_token.isEmpty()) { printExit();