All Projects → libmir → mir-cpuid

libmir / mir-cpuid

Licence: other
BetterC CPU Identification Routines

Programming Languages

d
599 projects
Meson
512 projects
Makefile
30231 projects

Projects that are alternatives of or similar to mir-cpuid

hardware
Get CPU, Memory and Network informations of the running OS and its processes
Stars: ✭ 70 (+180%)
Mutual labels:  cpu, system
ddcpuid
🔬 dd's x86 CPU Identification tool
Stars: ✭ 21 (-16%)
Mutual labels:  cpu, cpuid
cpuwhat
Nim utilities for advanced CPU operations: CPU identification, ISA extension detection, bindings to assorted intrinsics
Stars: ✭ 25 (+0%)
Mutual labels:  cpu, cpuid
clock
High-resolution clock functions: monotonic, realtime, cputime.
Stars: ✭ 52 (+108%)
Mutual labels:  cpu, system
Heim
Cross-platform async library for system information fetching 🦀
Stars: ✭ 572 (+2188%)
Mutual labels:  cpu, system
Sympact
🔥 Stupid Simple CPU/MEM "Profiler" for your JS code.
Stars: ✭ 439 (+1656%)
Mutual labels:  cpu, system
PyCPU
Central Processing Unit Information Gathering Tool
Stars: ✭ 19 (-24%)
Mutual labels:  cpu, cpuid
Iglance
Free system monitor for OSX and macOS. See all system information at a glance in the menu bar.
Stars: ✭ 1,358 (+5332%)
Mutual labels:  cpu, system
indicium
Portable, advanced system information utility
Stars: ✭ 46 (+84%)
Mutual labels:  cpu, system
sysfetch
A super tiny system information fetch script written in BASH
Stars: ✭ 197 (+688%)
Mutual labels:  system
ARM9-compatible-soft-CPU-core
This ARMv4-compatible CPU core is written in synthesiable verilog.It could launch uCLinux and Linux in MODELSIM. It has high Dhrystone benchmark value: 1.2 DMIPS/MHz. It could be utilized in your FPGA design as one submodule, if you master the interface of this .v file. This IP core is very compact. It is one .v file and has only less 1800 lines.
Stars: ✭ 42 (+68%)
Mutual labels:  cpu
SilentCryptoMiner
A Silent (Hidden) Free Crypto Miner Builder - Supports ETH, ETC, XMR and many more.
Stars: ✭ 547 (+2088%)
Mutual labels:  cpu
uecs
Micro ECS
Stars: ✭ 30 (+20%)
Mutual labels:  system
z80
Single header Z80 emulator for C++ (C++11 or later)
Stars: ✭ 17 (-32%)
Mutual labels:  cpu
cpu emulator
LMC emulator written in Rust
Stars: ✭ 32 (+28%)
Mutual labels:  cpu
cpu-memory-monitor
CPU & Memory Monitor, auto dump.
Stars: ✭ 26 (+4%)
Mutual labels:  cpu
cpuid
C++ library for detecting CPU capabilities
Stars: ✭ 82 (+228%)
Mutual labels:  cpuid
core
Liman Core allows you to centrally manage all servers in your IT processes remotely, with stable and secure. You can improve the features with expandable extensions and modules.
Stars: ✭ 35 (+40%)
Mutual labels:  system
AltairX
New computer and new CPU PoC
Stars: ✭ 38 (+52%)
Mutual labels:  cpu
yatcpu
Yet another toy CPU.
Stars: ✭ 42 (+68%)
Mutual labels:  cpu

Gitter

Build Status Build Status

Dub version Dub downloads License

CPU Information

void main()
{
    import std.stdio;
    import cpuid.unified;

    enum fmt = "%14s: %s";

    fmt.writefln("cores", cores);
    fmt.writefln("threads", threads);

    fmt.writefln("data caches", dCache.length);
    fmt.writefln("code caches", iCache.length);
    fmt.writefln("unified caches", uCache.length);

    fmt.writefln("data TLBs", dTlb.length);
    fmt.writefln("code TLBs", iTlb.length);
    fmt.writefln("unified TLBs", uTlb.length);
}

This package also can be used as workaround for core.cpuid Issue 16028.

Documentation

http://mir-cpuid.libmir.org

Testing

See all reports.

Run the following command from the project's directory to receive a report about your CPU

dub --single report.d

Please report dub log in a new GitHub issue!

See also output example.

Building a betterC library

BetterC mode works when compiled with LDC only.

dub build --compiler=ldmd2 --build-mode=singleFile --parallel

API Features

  • API was split to unified, target specified, and vendor specified parts.
  • Complex cache topology (number of cores per cache) is supported. This feature is required by ARM CPUs.
  • Translation lookaside buffers are supported. They are used in server and math software, for example cache optimized BLAS requires TLB information.
  • Caches and TLBs are split into three types:
    • Data
    • Instruction (code)
    • Unified (data and code)
  • _cpuid function is available for x86/x86-64 targets.

Implementation Features

  • The library was written completely from scratch.
  • Code is clean and simple.
  • Unions and mir.bitmanip.bitfields are used instead of bit operations.
  • Slim betterC library with extern(C) insterface.

TODO

  • Add information about recent features like AVX2, AVX512F.
  • Add information about ARM target and ARM vendors.
  • Test a lot of different CPUs.
  • Extend testing infrastructure.
  • CPU(package) count identification.
  • Per CPU(package) CPUID information.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].