seanmonstar/num_cpus

get_physical() returning wrong value with AMD 2970WX

Closed this issue · 0 comments

OS: Arch Linux 5.3.7
CPU: AMD Ryzen Threadripper 2970WX 24-Core Processor

It seems we're trying to count by core id, but that just marks the die that holds the cores. In this machine there are 6 dies with 4 cores each, and 2 threads per core. get_physical() returns 6, and when I checked the code it groups by core id. I also see a column cup cores that gives the right number 24 and could be used directly.