短程非键分子动力学模拟的代码现代化策略
Code modernization strategies for short-range non-bonded molecular dynamics simulations
AI总结:
针对现代HPC硬件特性,对ESPResSo++分子动力学模拟包进行代码现代化改造,通过数据布局优化、向量化及基于HPX的细粒度并行实现了显著性能提升。
摘要:
现代高性能计算(HPC)系统正越来越依赖更多的核心数和更宽的向量寄存器。因此,应用程序需要进行适配以充分利用这些硬件能力。分子动力学模拟是一类能从这种并行性提升中受益的应用。在本文中,我们介绍了对ESPResSo++分子动力学模拟软件包进行现代化改造的工作:通过重构其粒子数据布局以实现高效内存访问,并应用向量化技术来优化短程非键力的计算,最终实现了整体3倍的速度提升,可作为后续优化的基准。我们还通过HPX(一种采用轻量级线程和异步多任务方法以最大化并发性的C++运行时系统)为多核CPU实现了细粒度并行。我们的目标是评估基于HPX的方法与基于批量同步MPI的实现相比的性能。这需要在域分解方案中引入一个额外的层来定义任务粒度。在空间非均匀系统中,传统的基于MPI的方法会存在相应的负载不平衡,我们证明,通过选择最优的任务大小,HPX高效的工作窃取机制能够克服通信开销,相比基线MPI版本实现整体1.4倍的速度提升。
英文摘要:
Modern HPC systems are increasingly relying on greater core counts and wider vector registers. Thus, applications need to be adapted to fully utilize these hardware capabilities. One class of applications that can benefit from this increase in parallelism are molecular dynamics simulations. In this paper, we describe our efforts at modernizing the ESPResSo++ molecular dynamics simulation package by restructuring its particle data layout for efficient memory accesses and applying vectorization techniques to benefit the calculation of short-range non-bonded forces, which results in an overall three times speedup and serves as a baseline for further optimizations. We also implement fine-grained parallelism for multi-core CPUs through HPX, a C++ runtime system which uses lightweight threads and an asynchronous many-task approach to maximize concurrency. Our goal is to evaluate the performance of an HPX-based approach compared to the bulk-synchronous MPI-based implementation. This requires the introduction of an additional layer to the domain decomposition scheme that defines the task granularity. On spatially inhomogeneous systems, which impose a corresponding load-imbalance in traditional MPI-based approaches, we demonstrate that by choosing an optimal task size, the efficient work-stealing mechanisms of HPX can overcome the overhead of communication resulting in an overall 1.4 times speedup compared to the baseline MPI version.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。