arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2203.11028cs.AR
收藏

DSP-Packing:将低精度算术压缩进 FPGA DSP 模块

DSP-Packing: Squeezing Low-precision Arithmetic into FPGA DSP Blocks

Jan Sommer, M. Akif Özkan, Oliver Keszocze, Jürgen Teich

AI总结:

本文提出 DSP-Packing 方法,将低精度算术推广至任意位宽并打包进 FPGA DSP 模块,纠正了已有方法的误差,并引入近似方法 Overpacking 将单个 DSP 的 4 位乘法容量提升至六个,同时支持小位宽加法打包。

摘要:

现场可编程门阵列(FPGA)中可用的数字信号处理器(DSP)资源数量通常非常有限。因此,充分利用可用的 DSP 资源来处理算法中计算密集的部分,对于优化实现的非功能性属性(即性能、功耗和面积)至关重要。Xilinx 设备中的 DSP 实现了大位宽运算器(即 48 位累加器或 $18 \ imes 27$ 乘法器)。然而,将这样的 DSP 用于低精度量化数据(在图像处理或机器学习应用中很常见)会导致 DSP 资源未被充分利用。作为补救措施,已有方法提出在单个 DSP 上打包并在单个时钟周期内计算四个 4 位乘法。本文将该方案推广到任意位宽和乘法数量。我们还证明了先前提出的方法会导致误差(平均绝对误差(MAE)= 0.37)。此外,我们解释了这些误差的来源以及如何纠正它们。在此基础上,我们引入了一种名为“Overpacking”的新型近似方法,该方法允许以微小的误差(MAE = 0.47)为代价,将更多的乘法压缩到单个 DSP 中。与文献中仅有的四个相比,Overpacking 允许将六个 4 位乘法压缩到单个 DSP 中。最后,我们引入了一种替代方法,用于将多个小位宽加法打包到单个 48 位累加器中,以用于脉冲神经网络等应用。

英文摘要:

The number of Digital Signal Processor (DSP) resources available in Field Programmable Gate Arrays (FPGAs) is often quite limited. Therefore, full utilization of available DSP resources for the computationally intensive parts of an algorithm is paramount for optimizing the non-functional properties of an implementation (i.e., performance, power, and area). The DSPs available in Xilinx devices implement large bit width operators (i.e. a 48-bit accumulator or a $18 \times 27$ multiplier). However, using such a DSP for low-precision quantized data (as is common in image processing or machine learning applications) leaves the DSP resources underutilized. As a remedy, A method has been proposed to pack and compute four 4-bit multiplications on a single DSP in a single clock cycle. This paper presents a generalization of this scheme to arbitrary bit widths and number of multiplications. We also demonstrate that the previously proposed approach leads to errors (Mean Absolute Error (MAE) = 0.37). Furthermore, we explain where these errors come from and how they can be corrected. On top, we introduce a novel approximate method called "Overpacking" which allows to squeeze even more multiplications into a single DSP at the cost of small errors (MAE = 0.47). Overpacking allows to squeeze six 4-bit multiplications into a single DSP compared to just four in the literature. Finally, we introduce an alternative method for packing multiple small-bit width additions into a single 48-bit accumulator for use in applications such as Spiking Neural Networks.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑