krrishnarraj/clpeak

Peak compute, memory bandwidth and latency of CPUs, GPUs and NPUs: the same tests through every API that reaches a device. Command line and app for Windows, macOS, Linux and Android

clpeak – Compute‑Latency Benchmark

What it is – clpeak is a cross‑platform benchmark that measures the peak compute throughput, memory bandwidth and latency of CPUs, GPUs and NPUs. It runs tiny, highly‑tuned kernels through every available API (CUDA, ROCm/HIP, Metal, oneAPI/SYCL, Vulkan, OpenCL, ONNX Runtime, Core ML, LiteRT, etc.) and reports comparable numbers across devices.

Why it matters – When evaluating hardware for AI/ML workloads you need to know not just the theoretical specs but the real‑world performance of the underlying libraries (cuBLASLt, Core ML, etc.). clpeak gives you a single, reproducible way to see how fast a device can actually perform matrix‑multiply, convolution, and other core operations, plus the latency of kernel launches.

Key features

  • Multi‑backend support – CUDA, ROCm/HIP, Metal, oneAPI/SYCL, Vulkan, OpenCL, ONNX Runtime, Core ML, LiteRT.
  • CPU kernels compiled at runtime for the detected instruction set (x86‑64, AArch64).
  • Both CLI and GUI – command‑line tool works on Windows/macOS/Linux/Android; a Flutter‑based desktop app is also shipped.
  • JSON output & comparison – save a run, then re‑run and diff against the saved results.
  • Device‑level granularity – you can select specific devices/backends, list what is available, and run only chosen test categories (compute, bandwidth, latency, AI).
  • Cross‑platform builds – works on desktops and mobile (Android via Google Play, iOS via the app bundle).

Getting started

# Clone and build (requires CMake; optional Flutter SDK for the GUI)
git clone --recursive https://github.com/krrishnarraj/clpeak
cd clpeak
cmake -S . -B build
cmake --build build -j
./build/clpeak            # run the CLI

Pre‑built binaries are provided on the GitHub releases page and via the Snap Store. On Android you can install directly from Google Play.

Typical usage

# Run all tests on every detected device
clpeak

# List devices that clpeak can see
clpeak --list-devices

# Benchmark only the CUDA device 0 and Vulkan device 1
clpeak --devices cuda:0,vulkan:1

# Show only the memory‑bandwidth numbers
clpeak --bandwidth

# Save results to JSON for later comparison
clpeak -o run.clpeak.json
clpeak --compare run.clpeak.json

The --help flag lists all available options.

Where to find more – The project page (https://krrishnarraj.github.io/clpeak/) contains screenshots, detailed build instructions, and a list of supported backends. The AGENTS.md files document the repository layout for code‑generation agents, and results/ holds baseline runs for reference.

License – Distributed under the MIT License.


clpeak is a genuine, open‑source performance‑measurement tool aimed at developers, researchers and AI agents who need accurate, comparable hardware numbers across a wide range of compute platforms.

Related

  • Project
  • Project
  • Project
  • Project
  • Project