[论文解读] Accelerating HPC codes on Intel(R) Omni-Path Architecture networks: From particle physics to Machine Learning
本文提出优化技术,在使用 Xeon Phi 72xx 处理器的 Intel Omni-Path 架构集群上实现接近线路速度的性能,聚焦于两类工作负载:结构化网格 PDE 求解器中的 halo 交换和同步随机梯度下降中的梯度归约。通过利用 2MB 大页、多个 PSM2 端点以及 Intel MPI 2019 的线程并发特性,作者在百度研究院的归约核上实现了 10 倍的性能提升,展示了在 HPC 和机器学习工作负载中的显著性能增益。
We discuss practical methods to ensure near wirespeed performance from clusters with either one or two Intel(R) Omni-Path host fabric interfaces (HFI) per node, and Intel(R) Xeon Phi(TM) 72xx (Knight's Landing) processors, and using the Linux operating system. The study evaluates the performance improvements achievable and the required programming approaches in two distinct example problems: firstly in Cartesian communicator halo exchange problems, appropriate for structured grid PDE solvers that arise in quantum chromodynamics simulations of particle physics, and secondly in gradient reduction appropriate to synchronous stochastic gradient descent for machine learning. As an example, we accelerate a published Baidu Research reduction code and obtain a factor of ten speedup over the original code using the techniques discussed in this paper. This displays how a factor of ten speedup in strongly scaled distributed machine learning could be achieved when synchronous stochastic gradient descent is massively parallelised with a fixed mini-batch size. We find a significant improvement in performance robustness when memory is obtained using carefully allocated 2MB huge virtual memory pages, implying that either non-standard allocation routines should be used for communication buffers. These can be accessed via a LD\_PRELOAD override in the manner suggested by libhugetlbfs. We make use of a the Intel(R) MPI 2019 library Technology Preview and underlying software to enable thread concurrency throughout the communication software stake via multiple PSM2 endpoints per process and use of multiple independent MPI communicators. When using a single MPI process per node, we find that this greatly accelerates delivered bandwidth in many core Intel(R) Xeon Phi processors.
研究动机与目标
- 针对使用 Intel Omni-Path 架构和 Xeon Phi 72xx 处理器的集群,优化 HPC 和机器学习工作负载的通信性能。
- 评估内存分配策略(特别是 2MB 大页)对通信缓冲区性能的影响。
- 通过每个进程使用多个 PSM2 端点以及独立的通信器,在 MPI 通信栈中实现线程并发。
- 在两类代表性 HPC 工作负载中展示性能提升:结构化网格求解器中的 halo 交换和同步 SGD 中的梯度归约。
- 表明通过仔细的内存管理和通信栈调优,可在多 HFI 系统上实现接近线路速度的性能。
提出的方法
- 通过 LD_PRELOAD 覆盖并使用 libhugetlbfs,将通信缓冲区的虚拟内存页设置为 2MB 大页,以降低内存延迟并提高带宽。
- 采用 Intel MPI 2019 技术预览版,每个进程使用多个 PSM2 端点,以在通信中实现线程级并发。
- 利用多个独立的 MPI 通信器,隔离并加速多核环境中的通信操作。
- 优化用于量子色动力学模拟的结构化网格 PDE 求解器中笛卡尔通信器的 halo 交换通信模式。
- 将相同的优化技术应用于机器学习中同步随机梯度下降的梯度归约核。
- 在每个节点配备一个或两个 Omni-Path HFI 的系统上,使用每个节点单个 MPI 进程进行性能基准测试。
实验结果
研究问题
- RQ1如何在使用 Intel Omni-Path 架构和 Xeon Phi 72xx 处理器的集群上最大化通信性能?
- RQ22MB 大页在多大程度上提升了 MPI 通信缓冲区的性能?
- RQ3每个进程使用多个 PSM2 端点是否能显著提升多核环境下的交付带宽?
- RQ4在 halo 交换和梯度归约工作负载中,采用所提优化后可实现多大的性能提升?
- RQ5内存分配与 MPI 线程并发的结合如何影响端到端应用性能?
主要发现
- 通过应用所提优化技术,在公开发布的百度研究院梯度归约核上实现了 10 倍性能提升。
- 使用 2MB 大页显著提升了性能鲁棒性,表明非标准内存分配对高性能通信缓冲区至关重要。
- 每个进程使用多个 PSM2 端点实现了有效的线程并发,极大加速了多核 Xeon Phi 处理器上的交付带宽。
- 当每个节点仅使用单个 MPI 进程时,性能提升最为显著,凸显了进程到 HFI 映射的重要性。
- 大页与多个 MPI 通信器的结合,使 halo 交换和梯度归约工作负载均实现了接近线路速度的性能。
- 这些优化在固定小批量大小的强可扩展分布式机器学习中表现出显著增益,可实现更快收敛。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。