Skip to content

Commit

Permalink
Added --algo-perf-same-threshold option
Browse files Browse the repository at this point in the history
  • Loading branch information
MoneroOcean committed Feb 23, 2021
1 parent 93d2065 commit a2970bc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/base/net/stratum/AlgoSwitch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ bool AlgoSwitch::try_miner(const Miner* miner) const {
return false;
}
const float ratio = i1->second / m_miner_algo_perfs.size() / i2->second;
if (ratio > (1.0f + (float)(m_percent) / 100) || ratio < (1.0f - (float)(m_percent) / 100)) return false;
if (ratio > (1.0f + (float)(m_percent) / 100.0f) || ratio < (1.0f - (float)(m_percent) / 100.0f)) return false;
}
return true;
}
Expand Down
1 change: 1 addition & 0 deletions src/proxy/splitters/nicehash/NonceSplitter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ xmrig::Upstreams xmrig::NonceSplitter::upstreams() const
void xmrig::NonceSplitter::connect()
{
auto upstream = new NonceMapper(m_upstreams.size(), m_controller);
upstream->client()->set_algo_perf_same_threshold(m_controller->config()->algoPerfSameThreshold());
m_upstreams.push_back(upstream);

upstream->start();
Expand Down

0 comments on commit a2970bc

Please sign in to comment.