From 09be1a0e263c069c97036271a4ef4e9cb0d583fc Mon Sep 17 00:00:00 2001 From: boriselec Date: Thu, 22 Oct 2026 05:44:29 +0000 Subject: [PATCH] fix: correct Linux sysfs path for physical core detection --- src/core/util.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/util.cpp b/src/core/util.cpp index 7bd5c0bd1..a691b423c 100644 --- a/src/core/util.cpp +++ b/src/core/util.cpp @@ -343,7 +343,7 @@ int32_t sd_get_num_physical_cores() { // enumerate the set of thread siblings, num entries is num cores std::unordered_set siblings; for (uint32_t cpu = 0; cpu < UINT32_MAX; ++cpu) { - std::ifstream thread_siblings("/sys/devices/system/cpu" + std::to_string(cpu) + "/topology/thread_siblings"); + std::ifstream thread_siblings("/sys/devices/system/cpu/cpu" + std::to_string(cpu) + "/topology/thread_siblings"); if (!thread_siblings.is_open()) { break; // no more cpus }