1
0
mirror of https://github.com/xmrig/xmrig.git synced 2025-12-24 21:32:47 -05:00

Fixed Log usage

This commit is contained in:
MoneroOcean
2019-06-18 11:30:58 -07:00
parent 378292e84e
commit f49e566a9c
5 changed files with 3 additions and 729 deletions

View File

@@ -69,7 +69,7 @@ void Benchmark::onJobResult(const xmrig::JobResult& result) {
else if (now - m_time_start > static_cast<unsigned>(m_controller->config()->calibrateAlgoTime())*1000) { // end of becnhmark round for m_pa
const float hashrate = static_cast<float>(m_hash_count) * result.diff / (now - m_time_start) * 1000.0f;
m_controller->config()->set_algo_perf(m_pa, hashrate); // store hashrate result
Log::i()->text(m_controller->config()->isColors()
xmrig::Log::print(xmrig::Log::colors
? GREEN_BOLD(" ===> ") CYAN_BOLD("%s") WHITE_BOLD(" hashrate: ") CYAN_BOLD("%f")
: " ===> %s hasrate: %f",
xmrig::Algorithm::perfAlgoName(m_pa),

View File

@@ -251,7 +251,7 @@ void Workers::switch_algo(const xmrig::Algorithm& algorithm)
if (!str_threads.empty()) str_threads = str_threads + ", ";
str_threads = str_threads + "x" + std::to_string(thread->multiway());
}
Log::i()->text(m_controller->config()->isColors()
xmrig::Log::print(xmrig::Log::colors
? GREEN_BOLD(" >>> ") WHITE_BOLD("ALGO CHANGE: ") CYAN_BOLD("%s") ", " CYAN_BOLD("%d (%s)") " thread(s)"
: " >>> ALGO CHANGE: %s, %d (%s) thread(s)",
algorithm.name(),