paper-with-me

Papers

Highly Optimized Kernels and Fine-Grained Codebooks for LLM Inference on Arm CPUs

2024-12-23 · Dibakar Gope, David Mansell, Danny Loh, Ian Bratt

Large language models (LLMs) have transformed the way we think about language understanding and generation, enthralling both researchers and developers. However, deploying LLMs for inference has been a significant challenge due to their unprecedented size and resource requirements. While quantizing model weights to sub-byte precision has emerged as a promising solution to ease memory pressure, the group quantization formats commonly used for LLM quantization have significant compute overheads and a resource-intensive dequantization process. As a result, a higher proportion of compute instructions do not perform multiplies, i.e., real work, rendering them unsuitable for meeting the required latency requirements for LLMs deployed on commodity CPUs. In this work, we propose a set of highly optimized kernels to accelerate LLM inference and unleash the full potential of CPUs, particularly Arm CPUs. These kernels amortize the cost of loading the operands and the cost of weight unpacking across multiple output rows. This, along with the introduction of an optimized interleaved group data layout for weights and decompression path optimizations to reduce unnecessary operations and dequantization overhead while maximizing the use of vector and matrix multiply operations, significantly improves the efficiency of MAC operations. Furthermore, we present a groupwise non-uniform codebook-based quantization method for ultra-low-precision quantization of LLMs to better match non-uniform patterns in their weight distributions, demonstrating better throughput during token generation while ensuring better quality than the state-of-the-art. Applying these improvements to 4-bit LLMs results in a 3-3.2x improvement in prompt processing and a 2x improvement in autoregressive decoding on Arm CPUs, compared to LLaMA.cpp-based solution. The optimized kernels are available at https://github.com/ggerganov/llama.cpp.

📄 PDF Abstract BibTeX arXiv:2501.00032

Code (1)

ggerganov/llama.cpp 공식 구현 pytorch

Tasks

Quantization

Methods 이 논문이 사용한 방법론

SET Dynamic Sparse Training method where weight mask is updated randomly periodically
LLaMA LLaMA is a collection of foundation language models ranging from 7B to 65B parameters. It is based on the transformer architecture with various improvements that were…

Similar Papers 제목 키워드 기반

Semantic Codebooks as Effective Priors for Neural Speech Compression

2025-12-25 · Liuyang Bai, Weiyi Lu, Li Guo arxiv

Speech codecs are traditionally optimized for waveform fidelity, allocating bits to preserve acoustic detail even when much of it can be inferred from linguistic structure. This leads to inefficient compression and subop…

Synergizing Motion and Appearance: Multi-Scale Compensatory Codebooks for Talking Head Video Generation

2024-12-01 · CVPR 2025 1 · Shuling Zhao, Fa-Ting Hong, Xiaoshui Huang, Dan Xu

Talking head video generation aims to generate a realistic talking head video that preserves the person's identity from a source image and the motion from a driving video. Despite the promising progress made in the field…

Video Generation

SonicMoE: Accelerating MoE with IO and Tile-aware Optimizations

2025-12-16 · Wentao Guo, Mayank Mishra, Xinle Cheng, Ion Stoica 외 arxiv

Mixture of Experts (MoE) models have emerged as the de facto architecture for scaling up language models without significantly increasing the computational cost. Recent MoE models demonstrate a clear trend towards high e…

Tilus: A Virtual Machine for Arbitrary Low-Precision GPGPU Computation in LLM Serving

2025-04-17 · Yaoyao Ding, Bohan Hou, Xiao Zhang, Allan Lin 외

Serving Large Language Models (LLMs) is critical for AI-powered applications but demands substantial computational resources, particularly in memory bandwidth and computational throughput. Low-precision computation has e…

GPU

HipKittens: Fast and Furious AMD Kernels

2025-11-11 · William Hu, Drew Wadsworth, Sean Siddens, Stanley Winata 외 arxiv

AMD GPUs offer state-of-the-art compute and memory bandwidth; however, peak performance AMD kernels are written in raw assembly. To address the difficulty of mapping AI algorithms to hardware, recent work proposes C++ em…