uxlfoundation/oneDNN

Open-source library of optimized deep learning operations (matmul, convolution, attention) for CPUs (x64, AArch64, RISC-V) and Intel GPUs. Used by PyTorch, TensorFlow, OpenVINO, and ONNX Runtime.

What it solves

oneDNN provides a high-performance foundation for deep learning applications. It solves the problem of hardware fragmentation by offering a single, optimized library that accelerates essential AI operations—like matrix multiplication, convolution, and attention—across a wide variety of CPUs and GPUs.

How it works

The library detects your specific hardware at runtime and uses just-in-time (JIT) code generation to create specialized instructions tailored to your processor's cores, cache sizes, and instruction sets. It acts as an acceleration layer, meaning it is designed to be used by larger AI frameworks (like PyTorch or TensorFlow) rather than by end-users directly.

Who it’s for

It is primarily for developers of AI frameworks, deep learning libraries, and performance-critical applications who need to ensure their software runs efficiently on diverse hardware, including Intel, Arm, RISC-V, and various GPU architectures.

Highlights

  • Unified API: A single codebase supports multiple CPU architectures (Intel 64/AMD64, Arm, RISC-V) and Intel GPUs.
  • Hardware Specialization: Automatically optimizes performance based on the specific hardware detected at runtime.
  • Broad Precision Support: Handles a wide range of data types, including f32, bf16, f16, f8, f4, and various integer formats for efficient inference.
  • Operation Fusion: Combines multiple operations (like activations or attention mechanisms) into single, faster execution steps to reduce overhead.
  • Wide Interoperability: Works with standard threading models like OpenMP and TBB, and supports GPU execution via SYCL and OpenCL.

Related

  • Project
  • Project
  • Project
  • Project
  • Project