Skip to main content

perf_core_count

Function perf_core_count 

Source
pub fn perf_core_count() -> usize
Expand description

Number of performance cores, which is the useful width for a decode GEMV. On macOS this is hw.perflevel0.physicalcpu (llama.cpp reads the same key). Elsewhere it is physical_core_count — one logical CPU per physical core inside this process’s affinity mask — and only a host whose sysfs topology is unreadable falls all the way back to available_parallelism.