SPEED: Speculative Pipelined Execution for Efficient Decoding

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Hooper, Coleman, Kim, Sehoon, Mohammadzadeh, Hiva, Genc, Hasan, Keutzer, Kurt, Gholami, Amir, Shao, Sophia
Format: Preprint
Publié: 2023
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866917557934489600
author Hooper, Coleman
Kim, Sehoon
Mohammadzadeh, Hiva
Genc, Hasan
Keutzer, Kurt
Gholami, Amir
Shao, Sophia
author_facet Hooper, Coleman
Kim, Sehoon
Mohammadzadeh, Hiva
Genc, Hasan
Keutzer, Kurt
Gholami, Amir
Shao, Sophia
contents Generative Large Language Models (LLMs) based on the Transformer architecture have recently emerged as a dominant foundation model for a wide range of Natural Language Processing tasks. Nevertheless, their application in real-time scenarios has been highly restricted due to the significant inference latency associated with these models. This is particularly pronounced due to the autoregressive nature of generative LLM inference, where tokens are generated sequentially since each token depends on all previous output tokens. It is therefore challenging to achieve any token-level parallelism, making inference extremely memory-bound. In this work, we propose SPEED, which improves inference efficiency by speculatively executing multiple future tokens in parallel with the current token using predicted values based on early-layer hidden states. For Transformer decoders that employ parameter sharing, the memory operations for the tokens executing in parallel can be amortized, which allows us to accelerate generative LLM inference. We demonstrate the efficiency of our method in terms of latency reduction relative to model accuracy and demonstrate how speculation allows for training deeper decoders with parameter sharing with minimal runtime overhead.
format Preprint
id arxiv_https___arxiv_org_abs_2310_12072
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle SPEED: Speculative Pipelined Execution for Efficient Decoding
Hooper, Coleman
Kim, Sehoon
Mohammadzadeh, Hiva
Genc, Hasan
Keutzer, Kurt
Gholami, Amir
Shao, Sophia
Computation and Language
Generative Large Language Models (LLMs) based on the Transformer architecture have recently emerged as a dominant foundation model for a wide range of Natural Language Processing tasks. Nevertheless, their application in real-time scenarios has been highly restricted due to the significant inference latency associated with these models. This is particularly pronounced due to the autoregressive nature of generative LLM inference, where tokens are generated sequentially since each token depends on all previous output tokens. It is therefore challenging to achieve any token-level parallelism, making inference extremely memory-bound. In this work, we propose SPEED, which improves inference efficiency by speculatively executing multiple future tokens in parallel with the current token using predicted values based on early-layer hidden states. For Transformer decoders that employ parameter sharing, the memory operations for the tokens executing in parallel can be amortized, which allows us to accelerate generative LLM inference. We demonstrate the efficiency of our method in terms of latency reduction relative to model accuracy and demonstrate how speculation allows for training deeper decoders with parameter sharing with minimal runtime overhead.
title SPEED: Speculative Pipelined Execution for Efficient Decoding
topic Computation and Language
url https://arxiv.org/abs/2310.12072