Neuralink: Fast LLM Inference on Smartphones with Neuron Co-Activation Linking

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Wang, Tuowei, Fan, Ruwen, Huang, Minxing, Hao, Zixu, Li, Kun, Cao, Ting, Lu, Youyou, Zhang, Yaoxue, Ren, Ju
Format: Preprint
Published: 2024
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866918158903803904
author Wang, Tuowei
Fan, Ruwen
Huang, Minxing
Hao, Zixu
Li, Kun
Cao, Ting
Lu, Youyou
Zhang, Yaoxue
Ren, Ju
author_facet Wang, Tuowei
Fan, Ruwen
Huang, Minxing
Hao, Zixu
Li, Kun
Cao, Ting
Lu, Youyou
Zhang, Yaoxue
Ren, Ju
contents Large Language Models (LLMs) have achieved remarkable success across various domains, yet deploying them on mobile devices remains an arduous challenge due to their extensive computational and memory demands. While lightweight LLMs have been developed to fit mobile environments, they suffer from degraded model accuracy. In contrast, sparsity-based techniques minimize DRAM usage by selectively transferring only relevant neurons to DRAM while retaining the full model in external storage, such as flash. However, such approaches are critically limited by numerous I/O operations, particularly on smartphones with severe IOPS constraints. In this paper, we propose Neuralink, a novel approach that accelerates LLM inference on smartphones by optimizing neuron placement in flash memory. Neuralink leverages the concept of Neuron Co-Activation, where neurons frequently activated together are linked to facilitate continuous read access and optimize I/O efficiency. Our approach incorporates a two-stage solution: an offline stage that reorganizes neuron placement based on co-activation patterns, and an online stage that employs tailored data access and caching strategies to align well with hardware characteristics. Evaluations conducted on a variety of smartphones and LLMs demonstrate that Neuralink achieves on average $1.49\times$ improvements in end-to-end latency compared to the state-of-the-art. As the first solution to optimize storage placement under sparsity, Neuralink explores a new optimization space at the intersection of sparsity-driven algorithm and storage-level system co-design for LLM inference.
format Preprint
id arxiv_https___arxiv_org_abs_2410_19274
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Neuralink: Fast LLM Inference on Smartphones with Neuron Co-Activation Linking
Wang, Tuowei
Fan, Ruwen
Huang, Minxing
Hao, Zixu
Li, Kun
Cao, Ting
Lu, Youyou
Zhang, Yaoxue
Ren, Ju
Machine Learning
Artificial Intelligence
Operating Systems
Performance
Large Language Models (LLMs) have achieved remarkable success across various domains, yet deploying them on mobile devices remains an arduous challenge due to their extensive computational and memory demands. While lightweight LLMs have been developed to fit mobile environments, they suffer from degraded model accuracy. In contrast, sparsity-based techniques minimize DRAM usage by selectively transferring only relevant neurons to DRAM while retaining the full model in external storage, such as flash. However, such approaches are critically limited by numerous I/O operations, particularly on smartphones with severe IOPS constraints. In this paper, we propose Neuralink, a novel approach that accelerates LLM inference on smartphones by optimizing neuron placement in flash memory. Neuralink leverages the concept of Neuron Co-Activation, where neurons frequently activated together are linked to facilitate continuous read access and optimize I/O efficiency. Our approach incorporates a two-stage solution: an offline stage that reorganizes neuron placement based on co-activation patterns, and an online stage that employs tailored data access and caching strategies to align well with hardware characteristics. Evaluations conducted on a variety of smartphones and LLMs demonstrate that Neuralink achieves on average $1.49\times$ improvements in end-to-end latency compared to the state-of-the-art. As the first solution to optimize storage placement under sparsity, Neuralink explores a new optimization space at the intersection of sparsity-driven algorithm and storage-level system co-design for LLM inference.
title Neuralink: Fast LLM Inference on Smartphones with Neuron Co-Activation Linking
topic Machine Learning
Artificial Intelligence
Operating Systems
Performance
url https://arxiv.org/abs/2410.19274