Fixed dataset initialization speed on Linux if thread affinity was used.
This commit is contained in:
parent
ccd5fae5e1
commit
d4772cbd5d
9 changed files with 95 additions and 51 deletions
|
@ -24,6 +24,7 @@
|
|||
|
||||
|
||||
#include <algorithm>
|
||||
#include <thread>
|
||||
#include <uv.h>
|
||||
|
||||
|
||||
|
@ -38,6 +39,7 @@
|
|||
#include "core/Controller.h"
|
||||
#include "core/Miner.h"
|
||||
#include "crypto/common/Nonce.h"
|
||||
#include "crypto/rx/Rx.h"
|
||||
#include "rapidjson/document.h"
|
||||
#include "version.h"
|
||||
|
||||
|
@ -362,6 +364,11 @@ void xmrig::Miner::setJob(const Job &job, bool donate)
|
|||
d_ptr->userJobId = job.id();
|
||||
}
|
||||
|
||||
# ifdef XMRIG_ALGO_RANDOMX
|
||||
const CpuConfig &cpu = d_ptr->controller->config()->cpu();
|
||||
Rx::init(job, cpu.initThreads(), cpu.isHugePages());
|
||||
# endif
|
||||
|
||||
uv_rwlock_wrunlock(&d_ptr->rwlock);
|
||||
|
||||
d_ptr->handleJobChange(reset);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue