计算机工程与科学2025,Vol.47Issue(12):2119-2128,10.DOI:10.3969/j.issn.1007-130X.2025.12.004
面向天河超算的OpenFOAM不可压缩流体模拟算法优化
Incompressible fluid simulation algorithm optimization of OpenFOAM on Tianhe supercomputing
摘要
Abstract
The incompressible fluid simulation solvers in the open-source fluid dynamics software OpenFOAM exhibit cross-platform applicability.However,their performance optimizations are pre-dominantly tailored to supercomputing systems with existing architectures such as Intel,rendering their algorithmic optimizations unable to fully leverage the vectorized parallel advantages of the ARM archi-tecture on the Tianhe supercomputing system.To address this,this paper focuses on incompressible fluid simulation solvers as the research subject and employs ARM vectorization techniques to optimize their symmetric Gauss-Seidel(SGS)method and diagonal incomplete Cholesky preconditioned conjugate gradient(DIC-PCG)method,thereby enhancing the solver's operational efficiency.To achieve vectori-zation goals,this paper analyzes the relationships between neighboring grid cells during a single iteration of the two types of solving algorithms,revealing that the maximum number of neighboring cells is two and that there are no dependencies between them.Leveraging this prior knowledge,the original algorithm code is modified with minimal cost—specifically,by adding just four lines of if-else conditional statements—to vectorize the neighboring cells and accelerate the algorithms.Experimental results under various configurations demonstrate that the improved algorithm achieves a maximum single-core speedup of 1.75 and a maximum multi-core speedup of 149.16,with a parallel efficiency still reaching 29.13%.关键词
OpenFOAM/不可压缩流体模拟求解器/性能优化/单指令多数据(SIMD)/循环展开/内联汇编/加速比Key words
OpenFOAM/incompressible fluid simulation solver/performance optimization/single in-struction multiple data(SIMD)/loop unrolling/inline assembly/speedup rate分类
信息技术与安全科学引用本文复制引用
LIU Zhongmin,ZHANG Xiang,MA Di,SUN Yang,ZHOU Lei,QIU Qi,GONG Chunye..面向天河超算的OpenFOAM不可压缩流体模拟算法优化[J].计算机工程与科学,2025,47(12):2119-2128,10.基金项目
国家自然科学基金(62032023,42104078,61902411) (62032023,42104078,61902411)