[论文解读] High-speed turbulent flows towards the exascale: STREAmS-2 porting and performance
本文提出 STREAmS-2,一种适用于百亿亿次 HPC 系统的可移植、高性能可压缩流体求解器,通过新增 HIPFort 后端扩展其 CUDA Fortran 后端,以支持 AMD GPU。其在 512 个节点上实现了超过 95% 的弱可扩展性,使超音速与高超音速湍流流场的万亿网格点模拟成为可能。
Exascale High Performance Computing (HPC) represents a tremendous opportunity to push the boundaries of Computational Fluid Dynamics (CFD), but despite the consolidated trend towards the use of Graphics Processing Units (GPUs), programmability is still an issue. STREAmS-2 (Bernardini et al. Comput. Phys. Commun. 285 (2023) 108644) is a compressible solver for canonical wall-bounded turbulent flows capable of harvesting the potential of NVIDIA GPUs. Here we extend the already available CUDA Fortran backend with a novel HIPFort backend targeting AMD GPU architectures. The main implementation strategies are discussed along with a novel Python tool that can generate the HIPFort and CPU code versions allowing developers to focus their attention only on the CUDA Fortran backend. Single GPU performance is analysed focusing on NVIDIA A100 and AMD MI250x cards which are currently at the core of several HPC clusters. The gap between peak GPU performance and STREAmS-2 performance is found to be generally smaller for NVIDIA cards. Roofline analysis allows tracing this behavior to unexpectedly different computational intensities of the same kernel using the two cards. Parallel performance is measured on the two largest EuroHPC pre-exascale systems, LUMI (AMD GPUs) and Leonardo (NVIDIA GPUs). Strong scalability reveals more than 80% efficiency up to 16 nodes for Leonardo and up to 32 for LUMI. Weak scalability shows an impressive efficiency of over 95% up to the maximum number of nodes tested (256 for LUMI and 512 for Leonardo). This analysis shows that STREAmS-2 is the perfect candidate to fully exploit the power of current pre-exascale HPC systems in Europe, allowing users to simulate flows with over a trillion mesh points, thus reducing the gap between the Reynolds numbers achievable in high-fidelity simulations and those of real engineering applications.
研究动机与目标
- 解决在异构 HPC 架构中高保真 CFD 模拟的 GPU 可移植性挑战。
- 扩展 STREAmS-2 求解器以同时支持 NVIDIA 和 AMD GPU 架构,同时保持代码的可读性与可维护性。
- 在预百亿亿次系统上实现可压缩壁面湍流流场的大规模直接数值模拟(DNS)。
- 利用 Roofline 分析与通信避免模式,在不同 GPU 架构上优化性能。
- 在主要的 EuroHPC 预百亿亿次系统 LUMI 与 Leonardo 上实现接近理想的强可扩展性与弱可扩展性。
提出的方法
- 为 AMD GPU 架构开发了一种新型 HIPFort 后端,与现有的 CUDA Fortran 后端相辅相成。
- 设计了一种基于 Python 的代码生成工具,可自动将 CUDA Fortran 内核转换为 HIPFort 与 CPU 代码,确保一致性并降低维护开销。
- 采用面向对象的多后端软件架构,将算法逻辑与硬件特定实现解耦。
- 在 NVIDIA A100 与 AMD MI250x GPU 上开展单 GPU 性能分析,评估网格大小、循环并行化、线程掩码与分支发散的影响。
- 应用 Roofline 性能建模,识别不同 GPU 架构间计算强度的差异。
- 在 LUMI(AMD)与 Leonardo(NVIDIA)上,采用同步与异步通信模式,评估强可扩展性与弱可扩展性。
实验结果
研究问题
- RQ1在单节点配置下,STREAmS-2 在 NVIDIA A100 与 AMD MI250x GPU 上的性能表现如何?
- RQ2在不同 GPU 架构上,峰值 GPU 带宽与 STREAmS-2 实际性能之间的性能差距由何原因造成?
- RQ3在大规模 HPC 系统上,异步通信在多大程度上改善了强可扩展性与弱可扩展性?
- RQ4新 HIPFort 后端在 LUMI 等基于 AMD 的系统上能否实现与 CUDA Fortran 相当的性能?
- RQ5在当前预百亿亿次系统上,STREAmS-2 能够高效模拟的最大问题规模(以网格点数计)是多少?
主要发现
- 尽管理论峰值性能相似,STREAmS-2 在 NVIDIA A100 上的峰值 GPU 带宽与实际性能之间的差距小于在 AMD MI250x 上的差距。
- Roofline 分析表明,同一内核在 NVIDIA 与 AMD GPU 上的计算强度存在显著差异,解释了性能差异的原因。
- 在 Leonardo(NVIDIA)上,强可扩展性在最多 16 个节点时效率超过 80%;在 LUMI(AMD)上,最多 32 个节点时效率超过 80%,表现出优异的强可扩展性。
- 在 LUMI 上,弱可扩展性在最多 256 个节点时效率超过 95%;在 Leonardo 上,最多 512 个节点时效率超过 95%,表明接近理想的弱可扩展性。
- 与同步模式相比,异步通信将性能损失降低了 1% 至 2.5%,且在每个 GPU 网格尺寸较小时收益更大。
- 该系统能够高效模拟超过一万亿个网格点的流场,显著缩小了模拟与真实世界雷诺数之间的差距。
更好的研究,从现在开始
从阅读论文到最终审阅,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。