Although code generation for Convolution Neural Network (CNN) models has been extensively studied, performing efficient data slicing and parallelization for highly-constrai\-ned Multicore Neural Processor Units (NPUs) is still a challenging problem. Given the size of convolutions' input/output tensors and the small footprint of NPU on-chip memories, minimizing memory transactions while maximizing parallelism and MAC utilization are central to any effective solution. This paper proposes a TensorFlow XLA/LLVM compiler optimization pass for Multicore NPUs, called Tensor Slicing Optimization (TSO), which: (a) maximizes convolution parallelism and memory usage across NPU cores; and (b) reduces data transfers between host and NPU on-chip memories by using DRAM memory burst time estimates to guide tensor slicing. To evaluate the proposed approach, a set of experiments was performed using the NeuroMorphic Processor (NMP), a multicore NPU containing 32 RISC-V cores extended with novel CNN instructions. Experimental results show that TSO is capable of identifying the best tensor slicing that minimizes execution time for a set of CNN models. Speed-ups of up to 21.7\% result when comparing the TSO burst-based technique to a no-burst data slicing approach. To validate the generality of the TSO approach, the algorithm was also ported to the Glow Machine Learning framework. The performance of the models were measured on both Glow and TensorFlow XLA/LLVM compilers, revealing similar results.


翻译:尽管卷积神经网络(CNN)模型的代码生成已被广泛研究,但在高度约束的多核神经处理单元(NPU)上实现高效的数据切片与并行化仍具挑战性。鉴于卷积输入/输出张量的规模以及NPU片上存储器的有限容量,如何在最大化并行性与MAC利用率的同时最小化内存事务,是任何有效解决方案的核心问题。本文提出一种面向多核NPU的TensorFlow XLA/LLVM编译器优化步骤,称为张量切片优化(TSO),该方案能够:(a)最大化跨NPU核的卷积并行性与内存使用效率;(b)通过利用DRAM突发传输时间估计指导张量切片,减少主机与NPU片上存储器间的数据传输。为评估所提方法,我们使用神经形态处理器(NMP)——一种包含32个扩展了新型CNN指令的RISC-V核的多核NPU——开展了一系列实验。实验结果表明,TSO能够识别最佳张量切片方案,从而最小化一组CNN模型的执行时间。与无突发数据切片方法相比,基于TSO突发传输的技术可实现高达21.7%的加速比。为验证TSO方法的普适性,该算法还被移植至Glow机器学习框架。在Glow与TensorFlow XLA/LLVM两种编译器上对模型性能进行测量,结果显示两者性能表现相似。

0
下载
关闭预览

相关内容

【干货书】面向计算科学和工程的Python导论,167页pdf
专知会员服务
42+阅读 · 2021年4月7日
【ACML2020】张量网络机器学习:最近的进展和前沿,109页ppt
专知会员服务
55+阅读 · 2020年12月15日
【SIGGRAPH2019】TensorFlow 2.0深度学习计算机图形学应用
专知会员服务
41+阅读 · 2019年10月9日
动手实现推荐系统评价指标
机器学习与推荐算法
1+阅读 · 2022年6月1日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
基于PyTorch/TorchText的自然语言处理库
专知
28+阅读 · 2019年4月22日
SIGIR2019 接收论文列表
专知
18+阅读 · 2019年4月20日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
1+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
Arxiv
0+阅读 · 2023年5月24日
Arxiv
0+阅读 · 2023年5月24日
VIP会员
最新内容
无人机自主控制与人工智能:系统性综述
专知会员服务
10+阅读 · 今天7:25
巡飞弹与反无人机系统——现代战场的两大支柱
专知会员服务
3+阅读 · 今天6:54
《打造“黄金舰队”》57页报告
专知会员服务
3+阅读 · 今天6:52
《北约数字教官网络发展路径》128页报告
专知会员服务
2+阅读 · 今天6:33
ECCV 2026 | MIMFlow:MIM与归一化流统一图像生成
专知会员服务
7+阅读 · 6月25日
网状网络及其在军事领域的运用
专知会员服务
8+阅读 · 6月25日
无美国参与的欧洲战争方式(万字长文)
专知会员服务
8+阅读 · 6月25日
《国防领域敏感性分析白皮书》
专知会员服务
9+阅读 · 6月25日
综述 | 从问答到任务完成:Agent系统与Harness设计
专知会员服务
10+阅读 · 6月24日
Agentic RL:框架、实践与长程智能体训练
专知会员服务
10+阅读 · 6月24日
相关VIP内容
【干货书】面向计算科学和工程的Python导论,167页pdf
专知会员服务
42+阅读 · 2021年4月7日
【ACML2020】张量网络机器学习:最近的进展和前沿,109页ppt
专知会员服务
55+阅读 · 2020年12月15日
【SIGGRAPH2019】TensorFlow 2.0深度学习计算机图形学应用
专知会员服务
41+阅读 · 2019年10月9日
相关资讯
动手实现推荐系统评价指标
机器学习与推荐算法
1+阅读 · 2022年6月1日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
基于PyTorch/TorchText的自然语言处理库
专知
28+阅读 · 2019年4月22日
SIGIR2019 接收论文列表
专知
18+阅读 · 2019年4月20日
相关基金
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
1+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
Top
微信扫码咨询专知VIP会员