Skip to content
Failed

Changes

Summary

  1. Making num_draw_points in fill_holes a constant. We were already using this value as a constant everywhere, but passing a constant by argument list makes it difficult/impossible for a compiler to optimize using that constant, unless it does inlining. Now, rather than passing the constant num_hf_draw_points (or sometimes a hardcoded 2) we just use num_hf_draw_points directly from constants_clubb. This massively improves the performance of a loop in fill holes when using nvhpc+omp, which was the motivation for this, but should also improve the performance on CPUs. Everything is BFB. (details)
Commit 3abb325943da1a557e1213b2908ead3c828aff16 by Gunther Huebler
Making num_draw_points in fill_holes a constant. We were already using this value as a constant everywhere, but passing a constant by argument list makes it difficult/impossible for a compiler to optimize using that constant, unless it does inlining. Now, rather than passing the constant num_hf_draw_points (or sometimes a hardcoded 2) we just use num_hf_draw_points directly from constants_clubb. This massively improves the performance of a loop in fill holes when using nvhpc+omp, which was the motivation for this, but should also improve the performance on CPUs. Everything is BFB.
The file was modified src/CLUBB_core/fill_holes.F90 (diff)
The file was modified src/CLUBB_core/advance_xp2_xpyp_module.F90 (diff)
The file was modified src/CLUBB_core/advance_wp2_wp3_module.F90 (diff)
The file was modified src/Morrison_microphys/microphysics.F90 (diff)
The file was modified src/CLUBB_core/clubb_api_module.F90 (diff)
The file was modified src/CLUBB_core/advance_xm_wpxp_module.F90 (diff)
The file was modified src/CLUBB_core/advance_clubb_core_module.F90 (diff)