Contemporary Model Compression on Large Language Models Inference

Yite Wang, Dong LiuarXiv 2024 · DOI

Introduction

The "foundation model" era has introduced a significant entry barrier to AI research and deployment. Training state-of-the-art models like GPT-4 requires thousands of high-end GPUs and months of compute time, creating a substantial financial and environmental gap between elite laboratories and the broader community. Beyond training, real-time inference remains a challenge due to massive memory footprints and the quadratic computational scaling of standard architectures.

This survey provides a comprehensive roadmap for navigating these challenges—often referred to as the "GPU wall"—by exploring three pillars of efficiency: Model Design, System Design, and Model-System Co-Design. By synthesizing hundreds of recent techniques, the authors aim to make massive foundation models more affordable, accessible, and deployable across diverse hardware, from data centers to mobile devices.

Methodology: A Taxonomy of Efficiency

The landscape of model efficiency is categorized into three primary domains, as illustrated in the taxonomy below.

Taxonomy of techniques for Efficient Foundation Models, categorized into Model Design, System Design, and Model-System Co-design.

1. Model Design

Model design focuses on optimizing the internal architecture and parameter representation of the model.

  • Quantization: This involves reducing numerical precision (e.g., from FP32 to INT8, 4-bit, or even 1-bit). Methods like GPTQ and AWQ have established 4-bit quantization as a "gold standard," offering significant memory savings with minimal accuracy loss.
  • Knowledge Distillation (KD): A smaller "student" model is trained to mimic the behavior of a larger "teacher" model, effectively compressing the knowledge into a more efficient form.
  • Pruning: Redundant weights or neurons are removed. While unstructured pruning offers theoretical parameter reduction, structured pruning is often preferred for its compatibility with standard GPU memory access patterns.
Comparison of various quantization methods across different bit-widths and model types (LLMs and Diffusion models).

2. System Design

System design focuses on the infrastructure and data handling mechanisms that support model execution.

  • KV Cache Optimization: Managing the Key-Value (KV) cache is critical for long-context applications, where the cache size can exceed the model weights.
  • Token Reduction: Techniques that prune or merge less important tokens during processing to reduce the computational load.
  • Efficient Architectures: Exploring alternatives to standard Transformers, such as Linear Attention, State Space Models (SSMs like Mamba), and Long Convolutions, which offer better scaling properties.

3. Model-System Co-Design

This domain represents the intersection of algorithmic innovation and hardware optimization.

  • Mixture of Experts (MoE): Models that activate only a sparse fraction of their parameters for any given input, maintaining high capacity with lower active compute.
  • Mixed Precision Training (MPT): Dynamically assigning different precision levels to various layers to balance speed and stability.
  • Parameter-Efficient Fine-Tuning (PEFT): Methods like LoRA that update only a tiny fraction of weights, drastically reducing the overhead of adapting models to new tasks.

Key Insights and Results

The survey highlights a fundamental shift toward hardware-awareness. Theoretical efficiency (e.g., reducing FLOPs) does not always result in real-world speedups if the technique disrupts GPU-friendly memory patterns. Furthermore, sparsity is emerging as a dominant trend; models that are "large but sparse" (like MoE) allow for massive parameter counts while keeping per-token computation manageable.

Significant performance gains reported in the literature include:

  • Memory Efficiency: Tools like VL-Cache can reduce memory usage by up to 90% while improving decoding latency by 7x.
  • Compression: LLMPruner achieves a 20% reduction in parameters while maintaining 90% of the original performance.
  • Training Throughput: FlashAttention and its successors have revolutionized the field by making the attention mechanism "IO-aware," significantly accelerating training on long sequences.

Limitations and Future Directions

Despite rapid progress, several challenges remain. There is a persistent accuracy-efficiency trade-off, particularly at extremely low bit-widths (1-bit or 2-bit), where reasoning capabilities can degrade sharply. Additionally, many cutting-edge optimizations (like FP8 support) are hardware-dependent, requiring the latest generation of GPUs (e.g., NVIDIA H100).

Future research must address these gaps by focusing on diverse languages beyond English, extending efficiency techniques to multimodal architectures, and developing unified, user-friendly libraries that combine multiple optimization strategies seamlessly.

Summary updated

BibTeX
@misc{wang2024contemporary,
  author = {Yite Wang and Dong Liu},
  title = {{Contemporary Model Compression on Large Language Models Inference}},
  year = {2024},
  eprint = {2409.01990},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2409.01990},
}
Figure