Understanding and Optimizing Multi-Stage AI Inference Pipelines

要約

大規模な言語モデル(LLMS)の急速な進化により、ますます洗練された推論パイプラインとハードウェアプラットフォームの必要性が促進されています。
最新のLLMサービングは、検索拡張生成(RAG)、キー値(KV)キャッシュ検索、動的モデルルーティング、マルチステップ推論などのマルチステージプロセスを組み込んだ、従来のPrefillデコードワークフローを超えて拡張されています。
これらの段階は、GPU、ASIC、CPU、およびメモリ中心のアーキテクチャを統合する分散システムを必要とする多様な計算需要を示します。
ただし、既存のシミュレータには、これらの不均一なマルチエンジンワークフローをモデル化する忠実度があり、建築上の決定を通知する能力を制限しています。
このギャップに対処するために、エルメス、不均一なマルチステージLLM推論実行シミュレーターを紹介します。
エルメスは多様な要求段階をモデル化します。
RAG、KV検索、推論、Prefill、および複雑なハードウェア階層全体のデコードを含む。
Hermesは、以前のフレームワークとは異なり、高度なバッチング戦略とマルチレベルのメモリ階層を組み込んでいる間、複数のモデルを同時に実行する不均一なクライアントをサポートしています。
実際のハードウェアトレースを分析モデリングと統合することにより、エルメスは、ハイブリッドCPUアクセラターの展開におけるメモリ帯域幅の競合、クラスター間通信の遅延、バッチング効率などの重要なトレードオフをキャプチャします。
ケーススタディを通じて、推論段階がエンドツーエンドのレイテンシに与える影響、ハイブリッドパイプラインの最適なバッチング戦略、およびリモートKVキャッシュ検索のアーキテクチャの意味を調査します。
ヘルメスは、システムデザイナーがLLM推論の進化する状況をナビゲートするように力を与え、次世代のAIワークロードのハードウェアソフトウェアの共同設計を最適化するための実用的な洞察を提供します。

要約(オリジナル)

The rapid evolution of Large Language Models (LLMs) has driven the need for increasingly sophisticated inference pipelines and hardware platforms. Modern LLM serving extends beyond traditional prefill-decode workflows, incorporating multi-stage processes such as Retrieval Augmented Generation (RAG), key-value (KV) cache retrieval, dynamic model routing, and multi step reasoning. These stages exhibit diverse computational demands, requiring distributed systems that integrate GPUs, ASICs, CPUs, and memory-centric architectures. However, existing simulators lack the fidelity to model these heterogeneous, multi-engine workflows, limiting their ability to inform architectural decisions. To address this gap, we introduce HERMES, a Heterogeneous Multi-stage LLM inference Execution Simulator. HERMES models diverse request stages; including RAG, KV retrieval, reasoning, prefill, and decode across complex hardware hierarchies. HERMES supports heterogeneous clients executing multiple models concurrently unlike prior frameworks while incorporating advanced batching strategies and multi-level memory hierarchies. By integrating real hardware traces with analytical modeling, HERMES captures critical trade-offs such as memory bandwidth contention, inter-cluster communication latency, and batching efficiency in hybrid CPU-accelerator deployments. Through case studies, we explore the impact of reasoning stages on end-to-end latency, optimal batching strategies for hybrid pipelines, and the architectural implications of remote KV cache retrieval. HERMES empowers system designers to navigate the evolving landscape of LLM inference, providing actionable insights into optimizing hardware-software co-design for next-generation AI workloads.

arxiv情報

著者 Abhimanyu Rajeshkumar Bambhaniya,Hanjiang Wu,Suvinay Subramanian,Sudarshan Srinivasan,Souvik Kundu,Amir Yazdanbakhsh,Midhilesh Elavazhagan,Madhu Kumar,Tushar Krishna
発行日 2025-04-16 17:34:04+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.AI, cs.AR, cs.DC, cs.LG パーマリンク