GPU acceleration of CaNS for massively-parallel direct numerical simulations of canonical fluid flows

Pedro Costa, Everett Phillips, Luca Brandt, Massimiliano Fatica
1/15/2020
physics.flu-dyncs.CEphysics.comp-ph

Official code: maxcuda/CaNS (17 stars, MIT, last commit 2021-09-24).

Abstract

This work presents the GPU acceleration of the open-source code CaNS for very fast massively-parallel simulations of canonical fluid flows. The distinct feature of the many-CPU Navier-Stokes solver in CaNS is its fast direct solver for the second-order finite-difference Poisson equation, based on the method of eigenfunction expansions. The solver implements all the boundary conditions valid for this type of problems in a unified framework. Here, we extend the solver for GPU-accelerated clusters using CUDA Fortran. The porting makes extensive use of CUF kernels and has been greatly simplified by the unified memory feature of CUDA Fortran, which handles the data migration between host (CPU) and device (GPU) without defining new arrays in the source code. The overall implementation has been validated against benchmark data for turbulent channel flow and its performance assessed on a NVIDIA DGX-2 system (16 Tesla V100 32Gb, connected with NVLink via NVSwitch). The wall-clock time per time step of the GPU-accelerated implementation is impressively small when compared to its CPU implementation on state-of-the-art many-CPU clusters, as long as the domain partitioning is sufficiently small that the data resides mostly on the GPUs. The implementation has been made freely available and open-source under the terms of an MIT license.

View on arXivView PDF

Code Implementations(1)

maxcuda/CaNSOfficial100%
MIT

A code for fast, massively-parallel direct numerical simulations (DNS) of canonical flows

177Shell, MATLABDec 18, 20185 years agoMIT

Similar Papers

Cite this paper

@article{costa2020acceleration,
  title  = {GPU acceleration of CaNS for massively-parallel direct numerical simulations of canonical fluid flows},
  author = {Pedro Costa and Everett Phillips and Luca Brandt and Massimiliano Fatica},
  year   = {2020},
  eprint = {2001.05234},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2001.05234}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2001.05234.svg)](https://codeofpaper.com/paper/2001.05234)

Discussion