libcpuname
libcpuname is a Rust library that provides lookup tables for the names of CPU manufacturers and designers, CPU chip designs, and CPU core microarchitectures. The following instruction set architectures are supported:
- x86 (both 32-bit and 64-bit CPUs)
- ARM
- RISC-V
Quickstart
Add libcpuname to your project as a dependency:
cargo add libcpuname
Features
The architecture corresponding to the host's target triple is enabled by default via the native feature.
Other architectures can be enabled individually or wholesale.
The following features are available:
std(enabled by default): Link against thestdcrate. This enables impls ofstd::error::Errornative(enabled by default): Exposes the module that matches the host's target triplearm: Exposes thearmmoduleriscv: Exposes theriscvmodulex86: Exposes thex86module
License
libcpuname is dual-licensed under the Apache-2.0 and MIT open-source licenses.