当前位置: X-MOL 学术Adv. Aerodyn. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
Effects of mesh loop modes on performance of unstructured finite volume GPU simulations
Advances in Aerodynamics Pub Date : 2021-07-22 , DOI: 10.1186/s42774-021-00073-y
Yue Weng 1 , Xi Zhang 1 , Xianwei Zhang 1 , Yutong Lu 1 , Xiaohu Guo 2 , Yang Liu 3
Affiliation  

In unstructured finite volume method, loop on different mesh components such as cells, faces, nodes, etc is used widely for the traversal of data. Mesh loop results in direct or indirect data access that affects data locality significantly. By loop on mesh, many threads accessing the same data lead to data dependence. Both data locality and data dependence play an important part in the performance of GPU simulations. For optimizing a GPU-accelerated unstructured finite volume Computational Fluid Dynamics (CFD) program, the performance of hot spots under different loops on cells, faces, and nodes is evaluated on Nvidia Tesla V100 and K80. Numerical tests under different mesh scales show that the effects of mesh loop modes are different on data locality and data dependence. Specifically, face loop makes the best data locality, so long as access to face data exists in kernels. Cell loop brings the smallest overheads due to non-coalescing data access, when both cell and node data are used in computing without face data. Cell loop owns the best performance in the condition that only indirect access of cell data exists in kernels. Atomic operations reduced the performance of kernels largely in K80, which is not obvious on V100. With the suitable mesh loop mode in all kernels, the overall performance of GPU simulations can be increased by 15%-20%. Finally, the program on a single GPU V100 can achieve maximum 21.7 and average 14.1 speed up compared with 28 MPI tasks on two Intel CPUs Xeon Gold 6132.

中文翻译:

网格循环模式对非结构化有限体积 GPU 模拟性能的影响

在非结构化有限体积方法中,循环在不同的网格组件(如单元、面、节点等)上被广泛用于数据的遍历。网格循环会导致直接或间接的数据访问,从而显着影响数据局部性。通过网格上的循环,许多线程访问相同的数据导致数据依赖。数据局部性和数据依赖性在 GPU 模拟的性能中都扮演着重要的角色。为了优化 GPU 加速的非结构化有限体积计算流体动力学 (CFD) 程序,在 Nvidia Tesla V100 和 K80 上评估了单元、面和节点上不同循环下热点的性能。不同网格尺度下的数值试验表明,网格循环模式对数据局部性和数据依赖性的影响是不同的。具体来说,面部循环使数据局部性最佳,只要内核中存在对人脸数据的访问。当单元和节点数据都用于没有人脸数据的计算时,单元循环由于非合并数据访问带来最小的开销。在内核中仅存在单元数据的间接访问的情况下,单元循环具有最佳性能。原子操作在 K80 中很大程度上降低了内核的性能,这在 V100 上不明显。通过在所有内核中采用合适的网格循环模式,GPU 模拟的整体性能可以提高 15%-20%。最后,与两个 Intel CPU Xeon Gold 6132 上的 28 个 MPI 任务相比,单个 GPU V100 上的程序可以实现最高 21.7 和平均 14.1 的加速。在内核中仅存在单元数据的间接访问的情况下,单元循环具有最佳性能。原子操作在 K80 中很大程度上降低了内核的性能,这在 V100 上不明显。通过在所有内核中采用合适的网格循环模式,GPU 模拟的整体性能可以提高 15%-20%。最后,与两个 Intel CPU Xeon Gold 6132 上的 28 个 MPI 任务相比,单个 GPU V100 上的程序可以实现最高 21.7 和平均 14.1 的加速。在内核中仅存在单元数据的间接访问的情况下,单元循环具有最佳性能。原子操作在 K80 中很大程度上降低了内核的性能,这在 V100 上不明显。通过在所有内核中采用合适的网格循环模式,GPU 模拟的整体性能可以提高 15%-20%。最后,与两个 Intel CPU Xeon Gold 6132 上的 28 个 MPI 任务相比,单个 GPU V100 上的程序可以实现最高 21.7 和平均 14.1 的加速。
更新日期:2021-07-22
down
wechat
bug