From 20d555668bd55cd2e9c6574e7b033dbd3aa7d35b Mon Sep 17 00:00:00 2001 From: SChernykh <15806605+SChernykh@users.noreply.github.com> Date: Fri, 16 Aug 2024 23:36:22 +0200 Subject: [PATCH] Fixed threads auto-config on Zen5 --- src/backend/cpu/platform/HwlocCpuInfo.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/backend/cpu/platform/HwlocCpuInfo.cpp b/src/backend/cpu/platform/HwlocCpuInfo.cpp index f6137c31..eb83d02d 100644 --- a/src/backend/cpu/platform/HwlocCpuInfo.cpp +++ b/src/backend/cpu/platform/HwlocCpuInfo.cpp @@ -326,7 +326,8 @@ void xmrig::HwlocCpuInfo::processTopLevelCache(hwloc_obj_t cache, const Algorith } } - if (scratchpad == 2 * oneMiB) { + // This code is supposed to run only on Intel CPUs + if ((vendor() == VENDOR_INTEL) && (scratchpad == 2 * oneMiB)) { if (L2 && (cores.size() * oneMiB) == L2 && L2_associativity == 16 && L3 >= L2) { L3 = L2; extra = L2;