Porting WRF v4.8.0 to GPUs with OpenACC: strategy, verification, and lessons
Kilometer-scale simulations with the Weather Research and Forecasting (WRF) model run on CPU clusters are computationally intensive. GPUs offer higher peak arithmetic throughput per node. Earlier work on GPU-accelerated WRF either ported single physics schemes, built a proprietary code from an older WRF version, or re-implemented the model in another language. This leaves the question of how the community code with a complete real-case physics suite can run on GPUs and produce results physically consistent with CPU-based WRF. Here we port WRF v4.8.0 to NVIDIA GPUs with OpenACC directives and CUDA managed memory. The port covers the dynamical core, halo exchange, five microphysics schemes, four cumulus schemes, RRTMG radiation, three boundary layer schemes, two surface layer schemes, three land-surface models including Noah-MP version 5.0, the CLM lake model, spectral and analysis nudging, the HAILCAST hail diagnostic, and the WRF-Solar, WRF-Fire and WRF-Hydro components. Every change passed three gates: a per-call comparison with the previous code, byte identity of repeated runs, and a 7-day run compared with CPU-based WRF. On NSF NCAR Derecho, one node with four A100 GPUs ran 3.4 to 3.5 times faster than one 128-core CPU node at 5 km grid spacing and 6.1 times faster in a 7-day regional simulation at 9 km. Two GPU nodes ran two times faster than eight CPU nodes at 1 km, and in regional applications at 45 and 6 km one GPU node did the work of 3.8 and 9.0 CPU nodes, respectively. Across all cases, one GPU node replaced 3 to 9 CPU nodes. Differences from CPU WRF grew from round-off without systematic drift, and over a 30-day 45 km simulation daily-mean differences were significant at the 5 % level for 0 to 6.5 % of grid points, close to the rate expected by chance. The gates, the porting patterns, and the results we report give a route for routine GPU porting of numerical weather prediction models.
Authors
- Kristen Lani Rasmussen (ORCID: https://orcid.org/0000-0003-1321-0974)
- Weichen Liu (ORCID: https://orcid.org/0000-0001-8990-1216)
- Bart Geerts (ORCID: https://orcid.org/0000-0002-1508-6121)
- Jimy Dudhia (ORCID: https://orcid.org/0000-0002-2394-6232)
- Jesse Norris (ORCID: https://orcid.org/0000-0002-8988-3326)
- Stefan Rahimi (ORCID: https://orcid.org/0000-0003-3188-4462)
- Chad W. Thackeray (ORCID: https://orcid.org/0000-0002-3757-9015)
- Cenlin He (ORCID: https://orcid.org/0000-0002-7367-2815)
- Melissa Sue Bukovsky (ORCID: https://orcid.org/0000-0001-6415-965X)
- Tzu‐Shun Lin (ORCID: https://orcid.org/0000-0002-5741-8585)
- Fuxing Zhao (ORCID: https://orcid.org/0009-0000-1317-1368)
- Karandeep Singh
- Alex Hall
- Changhai Liu
- Lei Huang
Institutions
- NSF National Center for Atmospheric Research (US)
- University of Wyoming (US)
- University of California, Los Angeles (US)
- Colorado State University (US)
Publication Details
- Published
- 2026-12-02
- DOI
- https://doi.org/10.5194/egusphere-2026-7568-v1
- Primary Topic
- Parallel Computing and Optimization Techniques
- Type
- preprint