arXiv:2601.15710cs.ARcs.AI2026-01被引 3

用灵活库快速搭建专用大模型加速器,性能远超GPU。

FlexLLM: Composable HLS Library for Flexible Hybrid LLM Accelerator Design

  • 通过可组合HLS库,按阶段定制推理架构
  • 12.68的困惑度表现优于基线,速度提升4.71倍
  • 适合芯片设计者快速实现高效低功耗推理系统

我们提出FlexLLM,一个用于快速开发领域专用大模型加速器的可组合高层综合(HLS)库。该库暴露关键架构自由度,支持预填充与解码阶段差异化设计,实现时间重用与空间数据流的灵活配置,并提供全面的量化工具以支持高精度低比特部署。利用FlexLLM,仅用1000行代码在两个月内构建了针对Llama-3.2 1B模型的完整推理系统:(1) 基于阶段定制的加速器结合硬件高效的量化(12.68 WikiText-2 PPL),性能超越SpinQuant基线;(2) 集成分层内存Transformer(HMT)插件,实现高效长上下文处理。在AMD U280 FPGA(16nm)上,加速器相比运行BF16推理的NVIDIA A100 GPU(7nm)实现1.29×端到端提速、1.64×更高的解码吞吐量和3.14×更好的能效;在V80 FPGA(7nm)上的预测结果分别为4.71×、6.55×和4.13×。在长上下文场景中,集成HMT插件使预填充延迟降低23.23×,上下文窗口扩展64×,在U280/V80上分别实现1.10×/4.86×更低的端到端延迟和5.21×/6.27×更高的能效。因此,FlexLLM以极小人工成本连接大模型推理算法创新与高性能加速器设计。

原文摘要 · Abstract (English)

We present FlexLLM, a composable High-Level Synthesis (HLS) library for rapid development of domain-specific LLM accelerators. FlexLLM exposes key architectural degrees of freedom for stage-customized inference, enabling hybrid designs that tailor temporal reuse and spatial dataflow differently for prefill and decode, and provides a comprehensive quantization suite to support accurate low-bit deployment. Using FlexLLM, we build a complete inference system for the Llama-3.2 1B model in under two months with only 1K lines of code. The system includes: (1) a stage-customized accelerator with hardware-efficient quantization (12.68 WikiText-2 PPL) surpassing SpinQuant baseline, and (2) a Hierarchical Memory Transformer (HMT) plug-in for efficient long-context processing. On the AMD U280 FPGA at 16nm, the accelerator achieves 1.29$\times$ end-to-end speedup, 1.64$\times$ higher decode throughput, and 3.14$\times$ better energy efficiency than an NVIDIA A100 GPU (7nm) running BF16 inference; projected results on the V80 FPGA at 7nm reach 4.71$\times$, 6.55$\times$, and 4.13$\times$, respectively. In long-context scenarios, integrating the HMT plug-in reduces prefill latency by 23.23$\times$ and extends the context window by 64$\times$, delivering 1.10$\times$/4.86$\times$ lower end-to-end latency and 5.21$\times$/6.27$\times$ higher energy efficiency on the U280/V80 compared to the A100 baseline. FlexLLM thus bridges algorithmic innovation in LLM inference and high-performance accelerators with minimal manual effort.

大模型加速FPGA设计量化部署HLS

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。