Implemented BenchClient.

This commit is contained in:
XMRig 2020-10-24 19:43:23 +07:00
parent 36c1cb23e0
commit 79c96418c7
No known key found for this signature in database
GPG key ID: 446A53638BE94409
9 changed files with 200 additions and 18 deletions

View file

@ -44,6 +44,7 @@ xmrig::Benchmark::Benchmark(const Job &job, size_t workers, const IBackend *back
m_algo(job.algorithm()),
m_backend(backend),
m_workers(workers),
m_id(job.id()),
m_token(job.benchToken()),
m_end(job.benchSize()),
m_hash(job.benchHash())
@ -116,6 +117,10 @@ uint64_t xmrig::Benchmark::referenceHash() const
return m_hash;
}
if (!m_token.isEmpty()) {
return 0;
}
const uint32_t N = (m_end / 1000000) - 1;
if (((m_algo == Algorithm::RX_0) || (m_algo == Algorithm::RX_WOW)) && ((m_end % 1000000) == 0) && (N < 10)) {
return hashCheck[(m_algo == Algorithm::RX_0) ? 0 : 1][N];