Now used IThread to start threads, cpu-affinity broken, nonce allocation in double mode probably broken too.

This commit is contained in:
XMRig 2018-04-02 15:03:56 +07:00
parent 6c970612bf
commit 72cd6d168e
8 changed files with 47 additions and 38 deletions

View file

@ -33,17 +33,17 @@
Worker::Worker(Handle *handle) :
m_id(handle->threadId()),
m_threads(handle->threads()),
m_totalWays(handle->totalWays()),
m_hashCount(0),
m_timestamp(0),
m_count(0),
m_sequence(0)
{
if (Cpu::threads() > 1 && handle->affinity() != -1L) {
Cpu::setAffinity(m_id, handle->affinity());
}
// if (Cpu::threads() > 1 && handle->affinity() != -1L) {
// Cpu::setAffinity(m_id, handle->affinity());
// }
Platform::setThreadPriority(handle->priority());
Platform::setThreadPriority(handle->config()->priority());
m_ctx = Mem::create(m_id);
}