Removed code duplicate.

This commit is contained in:
XMRig 2020-05-09 01:13:46 +07:00
parent 85af4e27ec
commit 3cbf0dc0ee
No known key found for this signature in database
GPG key ID: 446A53638BE94409
16 changed files with 107 additions and 241 deletions

View file

@ -277,19 +277,7 @@ void xmrig::CpuBackend::prepare(const Job &nextJob)
# ifdef XMRIG_ALGO_ARGON2
const xmrig::Algorithm::Family f = nextJob.algorithm().family();
if ((f == Algorithm::ARGON2) || (f == Algorithm::RANDOM_X)) {
xmrig::String impl = d_ptr->controller->config()->cpu().argon2Impl();
if (impl.isEmpty()) {
if (xmrig::Cpu::info()->hasAVX2()) {
impl = "AVX2";
}
else if (xmrig::Cpu::info()->isX64()) {
impl = "SSE2";
}
}
if (argon2::Impl::select(impl)) {
if (argon2::Impl::select(d_ptr->controller->config()->cpu().argon2Impl())) {
LOG_INFO("%s use " WHITE_BOLD("argon2") " implementation " CSI "1;%dm" "%s",
tag,
argon2::Impl::name() == "default" ? 33 : 32,