Accelerating tensor multiplication by exploring hybrid product with hardware and software co-design

IF 4.1 2区 计算机科学 Q1 COMPUTER SCIENCE, HARDWARE & ARCHITECTURE Journal of Systems Architecture Pub Date : 2025-02-01 Epub Date: 2025-01-09 DOI:10.1016/j.sysarc.2025.103333
Zhiyuan Zhang, Zhihua Fan, Wenming Li, Yuhang Qiu, Zhen Wang, Xiaochun Ye, Dongrui Fan, Xuejun An
{"title":"Accelerating tensor multiplication by exploring hybrid product with hardware and software co-design","authors":"Zhiyuan Zhang,&nbsp;Zhihua Fan,&nbsp;Wenming Li,&nbsp;Yuhang Qiu,&nbsp;Zhen Wang,&nbsp;Xiaochun Ye,&nbsp;Dongrui Fan,&nbsp;Xuejun An","doi":"10.1016/j.sysarc.2025.103333","DOIUrl":null,"url":null,"abstract":"<div><div>Tensor multiplication holds a pivotal position in numerous applications. The existing accelerators predominantly rely on inner or outer products for their computational strategies, yet these methodologies encounter obstacles such as excessive storage overhead, underutilization of parallelism, and merging costs. To tackle the challenges, we propose an acceleration technique that integrates a hybrid product approach with a tailored hardware. Our design can accommodate tensor multiplications of various scales, boasting exceptional scalability. First, we employ a hybrid product approach for tensor multiplications, strategically leveraging various methods – including inner, outer, and Hadamard products – to optimize different stages of submatrices computations. Second, we devise a dedicated architecture that seamlessly aligns with hybrid product, leveraging dataflow paradigm to map tensor multiplication efficiently onto the hardware. Third, we design a sliding-window partial reuse FIFO (SWFIFO), alongside a data reorder and scheduling unit to accelerate data retrieval. For general matrix multiplication (GEMM), our design demonstrates an average speedup of <span><math><mrow><mn>17</mn><mo>.</mo><mn>62</mn><mo>×</mo></mrow></math></span> and 9.47% energy consumption over Nvidia’s V100 GPU. Furthermore, it surpasses Google’s TPU (size of 256 × 256) by an average of <span><math><mrow><mn>3</mn><mo>.</mo><mn>76</mn><mo>×</mo></mrow></math></span>, TPUv2 (size of 128 × 128) by <span><math><mrow><mn>3</mn><mo>.</mo><mn>19</mn><mo>×</mo></mrow></math></span> and Eyeriss by <span><math><mrow><mn>3</mn><mo>.</mo><mn>8</mn><mo>×</mo></mrow></math></span>. When evaluated on eight neural network models, our design yields a performance boost of <span><math><mrow><mn>2</mn><mo>.</mo><mn>89</mn><mo>×</mo></mrow></math></span> over TPU and <span><math><mrow><mn>2</mn><mo>.</mo><mn>19</mn><mo>×</mo></mrow></math></span> over Eyeriss.</div></div>","PeriodicalId":50027,"journal":{"name":"Journal of Systems Architecture","volume":"159 ","pages":"Article 103333"},"PeriodicalIF":4.1000,"publicationDate":"2025-02-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Journal of Systems Architecture","FirstCategoryId":"94","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S1383762125000050","RegionNum":2,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"2025/1/9 0:00:00","PubModel":"Epub","JCR":"Q1","JCRName":"COMPUTER SCIENCE, HARDWARE & ARCHITECTURE","Score":null,"Total":0}
引用次数: 0

Abstract

Tensor multiplication holds a pivotal position in numerous applications. The existing accelerators predominantly rely on inner or outer products for their computational strategies, yet these methodologies encounter obstacles such as excessive storage overhead, underutilization of parallelism, and merging costs. To tackle the challenges, we propose an acceleration technique that integrates a hybrid product approach with a tailored hardware. Our design can accommodate tensor multiplications of various scales, boasting exceptional scalability. First, we employ a hybrid product approach for tensor multiplications, strategically leveraging various methods – including inner, outer, and Hadamard products – to optimize different stages of submatrices computations. Second, we devise a dedicated architecture that seamlessly aligns with hybrid product, leveraging dataflow paradigm to map tensor multiplication efficiently onto the hardware. Third, we design a sliding-window partial reuse FIFO (SWFIFO), alongside a data reorder and scheduling unit to accelerate data retrieval. For general matrix multiplication (GEMM), our design demonstrates an average speedup of 17.62× and 9.47% energy consumption over Nvidia’s V100 GPU. Furthermore, it surpasses Google’s TPU (size of 256 × 256) by an average of 3.76×, TPUv2 (size of 128 × 128) by 3.19× and Eyeriss by 3.8×. When evaluated on eight neural network models, our design yields a performance boost of 2.89× over TPU and 2.19× over Eyeriss.
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
利用软硬件协同设计探索混合产品加速张量乘法
张量乘法在许多应用中占有举足轻重的地位。现有的加速器主要依赖于内部或外部产品的计算策略,然而这些方法遇到了诸如过多的存储开销、未充分利用并行性和合并成本等障碍。为了应对这些挑战,我们提出了一种将混合产品方法与定制硬件相结合的加速技术。我们的设计可以容纳各种尺度的张量乘法,具有卓越的可扩展性。首先,我们采用张量乘法的混合乘积方法,策略性地利用各种方法(包括内积、外积和Hadamard积)来优化子矩阵计算的不同阶段。其次,我们设计了一个与混合产品无缝对齐的专用架构,利用数据流范式将张量乘法有效地映射到硬件上。第三,我们设计了一个滑动窗口部分重用FIFO (SWFIFO),以及一个数据重排序和调度单元来加速数据检索。对于一般矩阵乘法(GEMM),我们的设计比Nvidia的V100 GPU平均加速17.62倍,能耗9.47%。此外,它比谷歌的TPU (256 × 256)平均高出3.76倍,比TPUv2 (128 × 128)平均高出3.19倍,比Eyeriss平均高出3.8倍。当在8个神经网络模型上进行评估时,我们的设计比TPU提高了2.89倍,比Eyeriss提高了2.19倍。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
Journal of Systems Architecture
Journal of Systems Architecture 工程技术-计算机:硬件
CiteScore
8.70
自引率
15.60%
发文量
226
审稿时长
46 days
期刊介绍: The Journal of Systems Architecture: Embedded Software Design (JSA) is a journal covering all design and architectural aspects related to embedded systems and software. It ranges from the microarchitecture level via the system software level up to the application-specific architecture level. Aspects such as real-time systems, operating systems, FPGA programming, programming languages, communications (limited to analysis and the software stack), mobile systems, parallel and distributed architectures as well as additional subjects in the computer and system architecture area will fall within the scope of this journal. Technology will not be a main focus, but its use and relevance to particular designs will be. Case studies are welcome but must contribute more than just a design for a particular piece of software. Design automation of such systems including methodologies, techniques and tools for their design as well as novel designs of software components fall within the scope of this journal. Novel applications that use embedded systems are also central in this journal. While hardware is not a part of this journal hardware/software co-design methods that consider interplay between software and hardware components with and emphasis on software are also relevant here.
期刊最新文献
Resource-efficient scheduling of parallel DAG tasks on identical multiprocessors On the power saving in high-speed Ethernet-based networks for supercomputers and data centers Distributed replica allocation and load balancing for Edge–Cloud FaaS Statistical prototype exchange and alignment for personalized federated learning FLSAMW: Mitigating backdoor attacks in federated learning based on SVD and amplified model weight
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:604180095
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1