Fix -check all runtime errors (for CCPP) using zero-size allocations #767
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR at least partially addresses ufs-community/ufs-weather-model#2023 (at least any runtime errors associated with the CCPP). The strategy is to simply make sure that every variable is allocated, although for variables that had been conditionally-allocated to save memory, they are now being allocated with zero size. This has a ripple effect in other repos where one needs to change from checking whether a variable is allocated to whether the size is > 0.
Note: There was also some cleanup done to remove variables that are declared in GFS_ and CCPP_typedefs.F90 but are not being used anywhere anymore. In addition, the ACTIVE attribute in the metadata files was double-checked for every conditionally-allocated variable.
Issue(s) addressed
ufs-community/ufs-weather-model#2023
Testing
This was tested with the full RT suite on Hera with the
-check all
compilation flag added in the ufs-weather-model Intel.cmake file. All tests completed successfully with no BL changes.Dependencies