NestedFP: High-Performance, Memory-Efficient Dual-Precision Floating Point Support for LLMs
Haeun Lee, Omin Kwon, Yeonhong Park, Jae W. Lee
TL;DR
The paper addresses meeting strict LLM inference SLOs under bursty demand by enabling dynamic, memory-efficient dual-precision serving. It introduces NestedFP, which overlays FP8 onto FP16 by decomposing FP16 weights into two 8-bit parts and reconstructing FP16 on-the-fly with a specialized CUTLASS-based GEMM kernel, achieving FP8 throughput without extra memory overhead. The approach yields FP8 model quality comparable to FP8 baselines and FP16 throughput nearly identical to standard FP16 pipelines, while significantly improving SLO attainment during load spikes. This work provides a practical pathway to balance latency, throughput, and quality in production LLM serving, with code available at the provided GitHub link.
Abstract
Meeting service-level objectives (SLOs) in Large Language Models (LLMs) serving is critical, but managing the high variability in load presents a significant challenge. Recent advancements in FP8 inference, backed by native hardware support, offer a potential solution: executing FP16 models by default, while switching to FP8 models during sudden load surges to achieve higher throughput at the cost of a slight quality degradation. Although this approach facilitates effective SLO management, it introduces additional memory overhead due to storing two versions of the same model. In response, this paper proposes NestedFP, an LLM serving technique that supports both FP16 and FP8 models in a memory efficient manner by overlaying FP8 parameters onto FP16 parameters, allowing both models to share the same FP16 memory footprint. By leveraging a compact data format for the overlay and a specialized GEMM kernel optimized for this format, NestedFP ensures minimal degradation in both model quality and inference throughput across both FP8 and FP16 modes. NestedFP provides a flexible platform for dynamic, SLO-aware precision selection. The code is available at https://github.com/SNU-ARC/NestedFP.
