通过MAC位权维度的变换探索张量处理引擎的性能提升
Exploring the Performance Improvement of Tensor Processing Engines through Transformation in the Bit-weight Dimension of MACs
AI总结:
本文从MAC位权维度提出细粒度TPE表示法及四种优化技术,在四种经典架构上显著提升面积与能效,位片架构下能效较Laconic提升12.10倍。
摘要:
通用矩阵-矩阵乘法(GEMM)是AI计算的基石,使得张量处理引擎(TPE)在GPU和领域专用架构中日益关键。现有架构主要优化数据流或操作数重用策略。然而,考虑矩阵乘法与乘累加器(MAC)之间的交互提供了更大的优化潜力。本文引入了一种关于矩阵乘法的新型硬件视角,聚焦于MAC的位权维度。我们以矩阵三重循环为例,提出了一种更细粒度的TPE表示法,引入了设计和优化PE微架构的新方法。基于该表示法及其变换,我们提出了四种优化技术,可改善时序、面积和功耗。我们使用SMIC-28nm工艺在RTL中实现设计,并在四种经典TPE架构上评估其有效性:脉动阵列、3D-Cube、乘法器-加法器树和2D-Matrix。我们的技术分别实现了1.27倍、1.28倍、1.56倍和1.44倍的面积效率提升,以及1.04倍、1.56倍、1.49倍和1.20倍的能效提升。应用于位片架构时,与Laconic相比,我们的方法实现了12.10倍的能效提升和2.85倍的面积效率提升。我们的Verilog HDL代码以及时序、面积和功耗报告可在https://github.com/wqzustc/High-Performance-Tensor-Processing-Engines获取。
英文摘要:
General matrix-matrix multiplication (GEMM) is a cornerstone of AI computations, making tensor processing engines (TPEs) increasingly critical in GPUs and domain-specific architectures. Existing architectures primarily optimize dataflow or operand reuse strategies. However, considering the interaction between matrix multiplication and multiply-accumulators (MACs) offers greater optimization potential. This work introduces a novel hardware perspective on matrix multiplication, focusing on the bit-weight dimension of MACs. We propose a finer-grained TPE notation using matrix triple loops as an example, introducing new methods for designing and optimizing PE microarchitectures. Based on this notation and its transformations, we propose four optimization techniques that improve timing, area, and power consumption. Implementing our design in RTL using the SMIC-28nm process, we evaluate its effectiveness across four classic TPE architectures: systolic array, 3D-Cube, multiplier-adder tree, and 2D-Matrix. Our techniques achieve area efficiency improvements of 1.27x, 1.28x, 1.56x, and 1.44x, and energy efficiency gains of 1.04x, 1.56x, 1.49x, and 1.20x, respectively. Applied to a bit-slice architecture, our approach achieves a 12.10x improvement in energy efficiency and 2.85x in area efficiency compared to Laconic. Our Verilog HDL code, along with timing, area, and power reports, is available at https://github.com/wqzustc/High-Performance-Tensor-Processing-Engines
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。