Efficient Code Generation of a Lattice Boltzmann Phase-Field Model for Immiscible Fluids with High Density Ratios and High Reynolds Numbers

M. Holzer
Abstract:In this thesis, a high-performance implementation of a multiphase lattice Boltzmann method (LBM) based on the conservative Allen-Cahn model supporting high density differences and high Reynolds numbers is presented.Metaprogramming techniques are used to generate optimised code for CPUs and GPUs automatically. The coupled model is specified in a high-level symbolic description and optimised through automatic transformations. The code generation approach allows investigating many different versions of the model, using different lattices and finite-difference approximations. A careful analysis of the generated models is done with the study of spurious currents around a static air bubble in liquid to examine the numerical accuracy. Further, validation of the implementation is shown in physically relevant scenarios– a three-dimensional rising air bubble in water and the Rayleigh-Taylor instability (RTI). The memory pressure of the resulting algorithm is reduced through the fusion of compute kernels. A roofline analysis demonstrates the excellent efficiency of the generated code on a single GPU. The resulting single GPU code can be integrated into the multiphysics framework waLBerla to run massively parallel simulations on huge domains. Communication hiding and GPUDirect-enabled MPI yield near-perfect scaling behaviour. Scaling experiments are conducted on the Piz Daint supercomputer with up to 2048 GPUs, simulating several hundred fully resolved bubbles.
Physics,Engineering
What problem does this paper attempt to address?