NCAR / micm

A model-independent chemistry module for atmosphere models
https://ncar.github.io/micm/
Apache License 2.0
6 stars 4 forks source link

Add GPU memory check for CUDA code #544

Closed sjsprecious closed 1 month ago

sjsprecious commented 1 month ago

This PR adds compute-sanitizer to check the GPU memory leak for all the CUDA tests.

Note that the compute-sanitizer looks for CUDA APIs in a code and will issue an error when applied to a CPU test. This error could not be suppressed unfortunately (https://docs.nvidia.com/compute-sanitizer/ComputeSanitizer/index.html#error-suppression). Therefore, we add new internal options to apply the compute-sanitizer check to the CUDA tests only.

All the 50 tests (including GPU memory check) are passed on Derecho's A100 GPU, using the nvhpc/23.7.

fix #415

codecov-commenter commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 92.25%. Comparing base (555be4e) to head (e13eeb0). Report is 2 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #544 +/- ## ======================================= Coverage 92.25% 92.25% ======================================= Files 45 45 Lines 3407 3407 ======================================= Hits 3143 3143 Misses 264 264 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.