mirror of
https://github.com/xmrig/xmrig.git
synced 2024-12-23 03:59:41 +00:00
Log cleanup.
This commit is contained in:
parent
32442db099
commit
eb1ed497e7
6 changed files with 27 additions and 33 deletions
|
@ -215,7 +215,7 @@ public:
|
|||
algo.l3() / 1024
|
||||
);
|
||||
|
||||
Log::print(WHITE_BOLD("| # | GPU | BUS ID | I | T | B | BF | BS | MEM | NAME"));
|
||||
Log::print(WHITE_BOLD("| # | GPU | BUS ID | INTENSITY | THREADS | BLOCKS | BF | BS | MEMORY | NAME"));
|
||||
|
||||
size_t algo_l3 = algo.l3();
|
||||
|
||||
|
@ -227,8 +227,8 @@ public:
|
|||
|
||||
size_t i = 0;
|
||||
for (const auto &data : threads) {
|
||||
Log::print("|" CYAN_BOLD("%3zu") " |" CYAN_BOLD("%4u") " |" YELLOW(" %7s") " |" CYAN_BOLD("%5d") " |" CYAN_BOLD("%4d") " |"
|
||||
CYAN_BOLD("%4d") " |" CYAN_BOLD("%3d") " |" CYAN_BOLD("%4d") " |" CYAN("%5zu") " | " GREEN("%s"),
|
||||
Log::print("|" CYAN_BOLD("%3zu") " |" CYAN_BOLD("%4u") " |" YELLOW(" %7s") " |" CYAN_BOLD("%10d") " |" CYAN_BOLD("%8d") " |"
|
||||
CYAN_BOLD("%7d") " |" CYAN_BOLD("%3d") " |" CYAN_BOLD("%4d") " |" CYAN("%7zu") " | " GREEN("%s"),
|
||||
i,
|
||||
data.thread.index(),
|
||||
data.device.topology().toString().data(),
|
||||
|
|
|
@ -24,17 +24,16 @@
|
|||
|
||||
|
||||
#include "backend/cuda/runners/CudaKawPowRunner.h"
|
||||
#include "3rdparty/libethash/data_sizes.h"
|
||||
#include "backend/cuda/CudaLaunchData.h"
|
||||
#include "backend/cuda/wrappers/CudaLib.h"
|
||||
#include "base/io/log/Log.h"
|
||||
#include "base/io/log/Tags.h"
|
||||
#include "base/net/stratum/Job.h"
|
||||
#include "base/tools/Chrono.h"
|
||||
|
||||
#include "crypto/kawpow/KPCache.h"
|
||||
#include "crypto/kawpow/KPHash.h"
|
||||
|
||||
#include "3rdparty/libethash/data_sizes.h"
|
||||
|
||||
|
||||
xmrig::CudaKawPowRunner::CudaKawPowRunner(size_t index, const CudaLaunchData &data) :
|
||||
CudaBaseRunner(index, data)
|
||||
|
@ -71,7 +70,7 @@ bool xmrig::CudaKawPowRunner::set(const Job &job, uint8_t *blob)
|
|||
|
||||
const int64_t dt = Chrono::steadyMSecs() - start_ms;
|
||||
if (dt > 500) {
|
||||
LOG_INFO("KawPow DAG for epoch %u calculated (%" PRIu64 " ms)", epoch, dt);
|
||||
LOG_INFO("%s " YELLOW("KawPow") " DAG for epoch " WHITE_BOLD("%u") " calculated " BLACK_BOLD("(%" PRIu64 "ms)"), Tags::nvidia(), epoch, dt);
|
||||
}
|
||||
|
||||
return result;
|
||||
|
|
|
@ -201,7 +201,7 @@ public:
|
|||
algo.l3() / 1024
|
||||
);
|
||||
|
||||
Log::print(WHITE_BOLD("| # | GPU | BUS ID | I | W | SI | MC | U | MEM | NAME"));
|
||||
Log::print(WHITE_BOLD("| # | GPU | BUS ID | INTENSITY | WSIZE | MEMORY | NAME"));
|
||||
|
||||
size_t algo_l3 = algo.l3();
|
||||
|
||||
|
@ -213,16 +213,13 @@ public:
|
|||
|
||||
size_t i = 0;
|
||||
for (const auto &data : threads) {
|
||||
Log::print("|" CYAN_BOLD("%3zu") " |" CYAN_BOLD("%4u") " |" YELLOW(" %7s") " |" CYAN_BOLD("%5u") " |" CYAN_BOLD("%3u") " |"
|
||||
CYAN_BOLD("%3u") " |" CYAN_BOLD("%3s") " |" CYAN_BOLD("%3u") " |" CYAN("%5zu") " | %s",
|
||||
Log::print("|" CYAN_BOLD("%3zu") " |" CYAN_BOLD("%4u") " |" YELLOW(" %7s") " |" CYAN_BOLD("%10u") " |" CYAN_BOLD("%6u") " |"
|
||||
CYAN("%7zu") " | %s",
|
||||
i,
|
||||
data.thread.index(),
|
||||
data.device.topology().toString().data(),
|
||||
data.thread.intensity(),
|
||||
data.thread.worksize(),
|
||||
data.thread.stridedIndex(),
|
||||
data.thread.stridedIndex() == 2 ? std::to_string(data.thread.memChunk()).c_str() : "-",
|
||||
data.thread.unrollFactor(),
|
||||
data.thread.intensity() * algo_l3 / oneMiB,
|
||||
data.device.printableName().data()
|
||||
);
|
||||
|
|
|
@ -23,23 +23,22 @@
|
|||
*/
|
||||
|
||||
|
||||
#include "backend/common/Tags.h"
|
||||
#include "backend/opencl/kernels/kawpow/KawPow_CalculateDAGKernel.h"
|
||||
#include "backend/opencl/runners/OclKawPowRunner.h"
|
||||
#include "backend/opencl/runners/tools/OclKawPow.h"
|
||||
#include "backend/common/Tags.h"
|
||||
#include "3rdparty/libethash/ethash_internal.h"
|
||||
#include "backend/opencl/kernels/kawpow/KawPow_CalculateDAGKernel.h"
|
||||
#include "backend/opencl/OclLaunchData.h"
|
||||
#include "backend/opencl/runners/tools/OclKawPow.h"
|
||||
#include "backend/opencl/wrappers/OclError.h"
|
||||
#include "backend/opencl/wrappers/OclLib.h"
|
||||
#include "base/io/log/Log.h"
|
||||
#include "base/net/stratum/Job.h"
|
||||
|
||||
#include "base/io/log/Log.h"
|
||||
#include "base/io/log/Tags.h"
|
||||
#include "base/net/stratum/Job.h"
|
||||
#include "base/tools/Chrono.h"
|
||||
#include "crypto/common/VirtualMemory.h"
|
||||
#include "crypto/kawpow/KPHash.h"
|
||||
|
||||
#include "3rdparty/libethash/ethash_internal.h"
|
||||
|
||||
|
||||
namespace xmrig {
|
||||
|
||||
|
@ -156,7 +155,7 @@ void OclKawPowRunner::set(const Job &job, uint8_t *blob)
|
|||
|
||||
OclLib::finish(m_queue);
|
||||
|
||||
LOG_INFO("KawPow DAG for epoch %u calculated (%" PRIu64 " ms)", epoch, Chrono::steadyMSecs() - start_ms);
|
||||
LOG_INFO("%s " YELLOW("KawPow") " DAG for epoch " WHITE_BOLD("%u") " calculated " BLACK_BOLD("(%" PRIu64 "ms)"), Tags::opencl(), epoch, Chrono::steadyMSecs() - start_ms);
|
||||
}
|
||||
|
||||
const uint64_t target = job.target();
|
||||
|
|
|
@ -23,7 +23,8 @@
|
|||
*/
|
||||
|
||||
#include "backend/opencl/runners/tools/OclKawPow.h"
|
||||
|
||||
#include "3rdparty/libethash/data_sizes.h"
|
||||
#include "3rdparty/libethash/ethash_internal.h"
|
||||
#include "backend/opencl/cl/kawpow/kawpow_cl.h"
|
||||
#include "backend/opencl/interfaces/IOclRunner.h"
|
||||
#include "backend/opencl/OclCache.h"
|
||||
|
@ -32,13 +33,11 @@
|
|||
#include "backend/opencl/wrappers/OclError.h"
|
||||
#include "backend/opencl/wrappers/OclLib.h"
|
||||
#include "base/io/log/Log.h"
|
||||
#include "base/io/log/Tags.h"
|
||||
#include "base/tools/Baton.h"
|
||||
#include "base/tools/Chrono.h"
|
||||
#include "crypto/kawpow/KPHash.h"
|
||||
|
||||
#include "3rdparty/libethash/ethash_internal.h"
|
||||
#include "3rdparty/libethash/data_sizes.h"
|
||||
|
||||
|
||||
#include <cstring>
|
||||
#include <mutex>
|
||||
|
@ -200,7 +199,7 @@ public:
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
LOG_INFO("KawPow program for period %" PRIu64 " compiled. (%" PRIu64 "ms)", period, Chrono::steadyMSecs() - ts);
|
||||
LOG_INFO("%s " YELLOW("KawPow") " program for period " WHITE_BOLD("%" PRIu64) " compiled " BLACK_BOLD("(%" PRIu64 "ms)"), Tags::opencl(), period, Chrono::steadyMSecs() - ts);
|
||||
|
||||
cache.add(runner.algorithm(), period, worksize, runner.deviceIndex(), program);
|
||||
|
||||
|
@ -238,7 +237,7 @@ private:
|
|||
int mix_seq_dst_cnt = 0;
|
||||
int mix_seq_cache_cnt = 0;
|
||||
|
||||
for (int i = 0; i < KPHash::REGS; i++) {
|
||||
for (uint32_t i = 0; i < KPHash::REGS; i++) {
|
||||
mix_seq_dst[i] = i;
|
||||
mix_seq_cache[i] = i;
|
||||
}
|
||||
|
@ -286,7 +285,7 @@ private:
|
|||
ret << merge("mix[0]", "data_dag.s[0]", rnd());
|
||||
|
||||
constexpr size_t num_words_per_lane = 256 / (sizeof(uint32_t) * KPHash::LANES);
|
||||
for (int i = 1; i < num_words_per_lane; i++)
|
||||
for (size_t i = 1; i < num_words_per_lane; i++)
|
||||
{
|
||||
std::string dest = mix_dst();
|
||||
uint32_t r = rnd();
|
||||
|
|
|
@ -27,14 +27,14 @@
|
|||
|
||||
#include <cinttypes>
|
||||
|
||||
#include "3rdparty/libethash/ethash.h"
|
||||
#include "3rdparty/libethash/ethash_internal.h"
|
||||
#include "crypto/kawpow/KPCache.h"
|
||||
#include "3rdparty/libethash/data_sizes.h"
|
||||
|
||||
#include "3rdparty/libethash/ethash_internal.h"
|
||||
#include "3rdparty/libethash/ethash.h"
|
||||
#include "base/io/log/Log.h"
|
||||
#include "base/io/log/Tags.h"
|
||||
#include "base/tools/Chrono.h"
|
||||
#include "crypto/common/VirtualMemory.h"
|
||||
#include "crypto/kawpow/KPCache.h"
|
||||
|
||||
|
||||
namespace xmrig {
|
||||
|
@ -90,7 +90,7 @@ bool KPCache::init(uint32_t epoch)
|
|||
m_size = size;
|
||||
m_epoch = epoch;
|
||||
|
||||
LOG_INFO("KawPow light cache for epoch %u calculated (%" PRIu64 " ms)", epoch, Chrono::steadyMSecs() - start_ms);
|
||||
LOG_INFO("%s " YELLOW("KawPow") " light cache for epoch " WHITE_BOLD("%u") " calculated " BLACK_BOLD("(%" PRIu64 "ms)"), Tags::miner(), epoch, Chrono::steadyMSecs() - start_ms);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue