Fixed auto-config

This commit is contained in:
SChernykh
2019-06-15 23:50:31 +02:00
parent aeba4aeea3
commit 93f6e8ec7d
2 changed files with 4 additions and 3 deletions

View File

@@ -160,7 +160,8 @@ bool xmrig::Config::finalize()
const AlgoVariant av = getAlgoVariant();
m_threads.mode = m_threads.count ? Simple : Automatic;
const size_t size = CpuThread::multiway(av) * cn_select_memory(m_algorithm.algo()) / 1024;
const Variant v = m_algorithm.variant();
const size_t size = CpuThread::multiway(av) * cn_select_memory(m_algorithm.algo(), v) / 1024;
if (!m_threads.count) {
m_threads.count = Cpu::info()->optimalThreadsCount(size, m_maxCpuUsage);