Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add sp mod #230

Merged
Merged

Conversation

AlexanderRichert-NOAA
Copy link
Contributor

@AlexanderRichert-NOAA AlexanderRichert-NOAA commented Feb 29, 2024

This PR puts the sp functionality under a Fortran module called sp_mod. Some downstream codes (namely UPP) will needs some tweaks as GCC at least is not accommodating of rank/type arguments in subroutine calls when modules are in play. That said, UPP builds successfully with a handful of minor changes, and grib-util, ufs-utils, and several UFS WM RTs are successfully built and tested with these changes.

Fixes #218

@AlexanderRichert-NOAA AlexanderRichert-NOAA marked this pull request as ready for review March 1, 2024 04:02
Copy link
Contributor

@Hang-Lei-NOAA Hang-Lei-NOAA left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For new application, this is good.
But when you put it into sp_mod, old/existing applications may have to add/include the sp_mod to use this version.

@AlexanderRichert-NOAA
Copy link
Contributor Author

@Hang-Lei-NOAA it'll be similar to what developers have already had to do with the existing ip modules, in that if they want to support new and old versions, they'll need to account for it in their cmake (i.e., conditional dependency of sp depending on ip version), and add code blocks like:

#ifdef USE_SP_MOD
use sp_mod, only: ...
#endif

@AlexanderRichert-NOAA AlexanderRichert-NOAA merged commit e10f624 into NOAA-EMC:develop Mar 4, 2024
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Put sp subroutines in Fortran modules
2 participants