SparAMX: Accelerating Compressed LLMs Token Generation on AMX-powered CPUs

Ahmed F. AbouElhamayed, Jordan Dotzel, Yash Akhauri, Chi-Chih Chang, Sameh Gobriel +4 more
2/18/2025
7 citations
cs.LGcs.AIcs.AR

Official code: IntelLabs/Hardware-Aware-Automated-Machine-Learning (78 stars, Python, MIT, last commit 2026-04-13).

Abstract

Large language models have high compute, latency, and memory requirements. While specialized accelerators such as GPUs and TPUs typically run these workloads, CPUs are more widely available and consume less energy.

Show full abstract

Accelerating LLMs with CPUs enables broader AI access at a lower cost and power consumption. This acceleration potential for CPUs is especially relevant during the memory-bound decoding stage of LLM inference, which processes one token at a time and is becoming increasingly utilized with reasoning models. We utilize Advanced Matrix Extensions (AMX) support on the latest Intel CPUs together with unstructured sparsity to achieve a $1.42 \times$ reduction in end-to-end latency compared to the current PyTorch implementation by applying our technique in linear layers. We provide a set of open-source customized sparse kernels that can speed up any PyTorch model by automatically replacing all linear layers with our custom sparse implementation. Furthermore, we demonstrate for the first time the use of unstructured sparsity in the attention computation achieving a $1.14 \times$ speedup over the current systems without compromising accuracy. Code: https://github.com/IntelLabs/Hardware-Aware-Automated-Machine-Learning/tree/main/SparAMX

View on arXivView PDF

Code Implementations(1)

MIT
7816Python, Jupyter NotebookOct 10, 20227 months agoMIT

Similar Papers

Cite this paper

@article{abouelhamayed2025sparamx,
  title  = {SparAMX: Accelerating Compressed LLMs Token Generation on AMX-powered CPUs},
  author = {Ahmed F. AbouElhamayed and Jordan Dotzel and Yash Akhauri and Chi-Chih Chang and Sameh Gobriel and J. Pablo Muñoz and Vui Seng Chua and Nilesh Jain and Mohamed S. Abdelfattah},
  year   = {2025},
  eprint = {2502.12444},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.12444v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2502.12444.svg)](https://codeofpaper.com/paper/2502.12444)

Discussion