Skip to main content
QUICK REVIEW

[论文解读] Optimized implementation of the conjugate gradient algorithm for FPGA-based platforms using the Dirac-Wilson operator as an example

G. Korcyl, Piotr Korcyl|arXiv (Cornell University)|Jan 15, 2020
Quantum Computing Algorithms and Architecture参考文献 6被引用 6
一句话总结

本论文提出了一种基于FPGA的共轭梯度(CG)算法优化实现,采用狄拉克-威尔逊算符作为格点量子色动力学(lattice QCD)模拟中复数稀疏线性系统的代表性算子。该实现基于Xilinx U280平台,采用OpenCL与C++编程,通过隐藏数据传输和流水线内存访问,在300 MHz时钟频率下实现了607 GFLOPS的性能,展示了面向FPGA加速器的高性能、可复用HPC应用框架。

ABSTRACT

It is now a noticeable trend in High Performance Computing that the systems are becoming more and more heterogeneous. Compute nodes with a host CPU are being equipped with accelerators, the latter being a GPU or FPGA cards or both. In many cases at the heart of scientific applications running on such systems are iterative linear solvers. In this work we present a software package which includes an FPGA implementation of the Conjugate Gradient algorithm using a particular problem of the Dirac-Wilson operator as encountered in numerical simulations of Quantum Chromodynamics. The software is written in OpenCL and C++ and is optimized for maximal performance. Our framework allows for a simple implementation of other linear operators, while keeping the data transport mechanisms unaltered. Hence, our software can serve as a backbone for many applications which are expected to gain a significant boost factor on FPGA accelerators. As such systems are expected to become more and more widespread, the need for highly performant FPGA implementations of the Conjugate Gradient algorithm and its variants will certainly increase and the porting investment can be greatly facilitated by the attached code.

研究动机与目标

  • 开发一种面向异构HPC系统的高性能、可复用FPGA实现的共轭梯度算法。
  • 解决将迭代线性求解器移植到FPGA加速器时,针对新算子仅需最小代码修改的挑战。
  • 通过先进的内存与内核优化技术,最大化计算资源利用率并最小化数据移动开销。
  • 提供一个可投入生产的软件堆栈,可作为FPGA加速系统上HPC应用与HPCG基准测试的骨干架构。
  • 证明FPGA在处理稀疏、结构化线性系统等特定HPC工作负载时,可超越CPU与GPU的性能表现。

提出的方法

  • CG算法在Xilinx Alveo U280 FPGA上使用OpenCL与C++实现,采用双精度浮点变体以提升性能。
  • 内核配置为2周期启动间隔,并在300 MHz频率下运行,以最大化吞吐量。
  • 采用循环缓冲技术,实现数据传输与内核计算的重叠,隐藏内存延迟。
  • 三个高性能内存(HBM)通道将输入数据流式传输至FPGA,而单个HBM3通道负责返回结果,实现连续运行。
  • 使用自定义数据类型与优化的内存访问模式,处理基于4D网格的狄拉克-威尔逊算符,其每个星形(stencil)包含复数矩阵条目。
  • 设计采用非阻塞主机同步机制,确保所有数据传输均与计算重叠,最大化资源利用率。

实验结果

研究问题

  • RQ1基于FPGA的CG实现能否在大规模稀疏线性系统上达到与现代CPU和GPU相当的性能?
  • RQ2如何有效重叠数据移动与内核执行,以最大化迭代求解器在FPGA上的资源利用率?
  • RQ3CG内核在不重构核心逻辑的前提下,其抽象程度能达到何种水平以支持不同线性算子?
  • RQ4在FPGA硬件上,通过优化内存访问与流水线数据流,可实现多大的性能提升?
  • RQ5所提出的框架能否作为FPGA加速系统上HPC应用与HPCG基准测试的可移植骨干架构?

主要发现

  • 在Xilinx U280平台上,FPGA实现达到了607 GFLOPS的持续性能,超过64核Intel Xeon Phi,且与Nvidia V100 GPU在相同算法下的性能持平。
  • 内核以2周期启动间隔、300 MHz时钟频率运行,实现了高吞吐量与高效的资源利用率。
  • 通过输入流式传输与输出返回的计算重叠,完全隐藏了数据传输延迟,确保了内核执行的不间断性。
  • 通过保持相同的数据传输与内核接口,该框架支持其他线性算子的复用,可实现新HPC应用的快速移植。
  • 该实现表明,FPGA能够提供低延迟、确定性的通信与高算术强度,特别适合具有复杂内存访问模式的HPC工作负载。
  • 该软件包已可投入生产使用,采用GNU GPL开源协议发布,并附带文档与集成至新HPC系统的技术支持。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。