Add a dm_info object to the argument list of core mpas_setup_packages_function - #1463
Merged
Merged
Conversation
…_function Adding a dm_info object allows a core's package setup function to make use of MPI when setting up packages. For example, a core may read data from a file only on MPI rank 0 and broadcast the resulting values to other MPI ranks rather than having each MPI rank independently open and read the file. In addition to updating the mpas_setup_packages_function abstract interface in mpas_core_types.inc with an additional 'dminfo' argument, this commit updates the call to domain_ptr % core % setup_packages in mpas_init to include the dminfo argument, and it also updates the *_setup_packages functions in each core's interface module.
abishekg7
approved these changes
Jun 2, 2026
abishekg7
left a comment
Collaborator
There was a problem hiding this comment.
Looks good. Checked with gnu, intel and nvhpc builds. And also with atmosphere, init_atmosphere, sw cores.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR adds a
dm_infoobject to the argument list of thempas_setup_packages_functioncore interface function. Adding adm_infoobject allows a core's package setup function to make use of MPI when setting up packages. For example, a core may read data from a file only on MPI rank 0 and broadcast the resulting values to other MPI ranks rather than having each MPI rank independently open and read the file.In addition to updating the
mpas_setup_packages_functionabstract interface inmpas_core_types.incwith an additionaldminfoargument, this PR updates the call todomain_ptr % core % setup_packagesinmpas_initto include thedminfoargument, and it also updates the*_setup_packagesfunctions in each core's interface module.