Crate atopology[−][src]
Interface to query information about the underlying hardware.
Our naming scheme follows the Intel x86/ACPI convention which has a thread/core/package/NUMA node hierarchy:
- thread: Hardware scheduling unit (has an APIC, is an app or core bsp core)
- core: one or more threads (usually 2)
- package: one or more cores (usually a socket with a shared LLC)
- affinity region: a NUMA node (consists of a bunch of threads/core/packages and memory regions)
Intel Topology is a pretty complicated subject (unfortunately), relevant documentation is here:
- https://software.intel.com/en-us/articles/intel-64-architecture-processor-topology-enumeration/
- https://acpica.org/documentation
Structs
Core | Represents a core in the system. |
MACHINE_TOPOLOGY | A struct that contains all information about current machine we’re running on (discovered from ACPI Tables and cpuid). |
MachineInfo | Contains a condensed and filtered version of all data queried from ACPI and CPUID. |
Node | Represents a NUMA node in the system. |
Package | Represents a package/socket in the system. |
Thread | Represents an SMT thread in the system. |
Type Definitions
CoreId | A core, with one or more threads (unique within a packet). |
GlobalThreadId | A system global ID for a CPU. |
NodeId | Affinity region, a NUMA node (consists of a bunch of threads/core/packages and memory regions). |
PackageId | A socket with one or more cores (usually with a shared LLC). |
ThreadId | A hardware scheduling unit (has an APIC), (unique within a core). |