Thanks to the ongoing development of Earth System Models, the simulation results become more accurate and physically comprehensive. In connection with this progress, we are also facing multiple serious challenges. First of all, the physical complexity, as well as the spatial and temporal resolution of modern ocean, atmosphere and climate models, is increasing. In addition, enormous computational resources needed by such models put a priority on the computational and energy efficiency issues. Furthermore, due to the rapidly changing computing architectures, a model code needs to be easily portable to new computational platforms over the course of its lifetime.
To meet these challenges, domain-specific languages (DSLs) together with code generation techniques seem to be a promising approach. DSLs are computer languages restricted to one specific application domain. Thereby, they can concurrently offer a good run-time performance comparable to that from a highly optimized FORTRAN or C++ code and the ease of implementation of scripting languages such as Python. Code generation techniques then allow targeting different hardware architectures while automatically applying domain-specific optimizations.
The main focus of our recent work is to propose and investigate several techniques that aim to substantially improve the computational performance of ocean models. To that end, we introduced a new quadrature-free discontinuous Galerkin (DG) scheme for the shallow water equations (SWE). The new scheme has been implemented as an extension of the DSL framework ExaStencils using a Python-based formulation of the numerical scheme. In order to enable computational performance optimizations possible for structured-mesh models, we created for the first time a block-structured grid generation methodology for realistic ocean domains.
Our new approach shows a considerable performance improvement compared to that of a standard SWE solver that uses a quadrature-based DG scheme while achieving comparable accuracy and stability on block-structured grids. Currently, next to optimizing the code generation pipeline, we are integrating p-adaptivity (local approximation space refinement) into our framework. Furthermore, we are investigating different approaches to generate block-structured grids for much more complicated domains. In our future work, we consider transferring our techniques to 3D coastal ocean models.
Faghih-Naini, Sara; Aizinger, Vadym; Kuckuk, Sebastian; Zint, Daniel; Grosso, Roberto; Köstler, Harald (2020): Quadrature-free discontinuous Galerkin method with code generation features for shallow water equations on automatically generated block-structured meshes. Advances in Water Resources vol. 138. doi:10.1016/j.advwatres.2020.103552 ...