-
Notifications
You must be signed in to change notification settings - Fork 178
Update MPAS dynamical core to version 8.4.0 #1545
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
Open
kuanchihwang
wants to merge
10
commits into
ESCOMP:cam_development
Choose a base branch
from
kuanchihwang:staging/mpas-dycore-8.4.0
base: cam_development
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
591d871
Update MPAS dynamical core to version 8.4.0
kuanchihwang cc28a67
Update Makefile to fix build errors
kuanchihwang 18eedac
Remove unnecessary Makefile build target
kuanchihwang 0e228df
Add patches to fix crash in MPAS 8.4.0
kuanchihwang 9e2d7be
Update namelist definitions, defaults, and input to accommodate MPAS …
kuanchihwang aac7f4f
Add support for new deformation coefficients introduced in MPAS 8.4.0
kuanchihwang 0b72a2f
Remove deprecated variables that no longer exist
kuanchihwang 16105f6
Define new constituent indexes required by MPAS 8.4.0
kuanchihwang 2e2517a
Remove debugging print
kuanchihwang 9071510
Merge branch 'cam_development' into develop/mpas-dycore-8.4.0
kuanchihwang File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
45 changes: 45 additions & 0 deletions
45
src/dynamics/mpas/driver/0001-Fix-Fortran-standard-violation.patch
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 | ||
| From: Kuan-Chih Wang <kuanchihw@ucar.edu> | ||
| Date: Tue, 21 Apr 2026 13:50:09 -0600 | ||
| Subject: [PATCH] Fix Fortran standard violation due to pointer argument not | ||
| being associated | ||
|
|
||
| At line 1970, if the `DO_PHYSICS` macro is undefined, the `diag_physics` pointer | ||
| will not be initialized by the call to `mpas_pool_get_subpool`, and therefore | ||
| its pointer association status will remain undefined. | ||
|
|
||
| However, at line 2250, this pointer is used as an argument to call `atm_compute_dyn_tend`, | ||
| which constitutes a Fortran standard violation. | ||
|
|
||
| Quoted from Fortran 2023, | ||
|
|
||
| > 15.5.2.4 Argument association | ||
| > Except in references to intrinsic inquiry functions, a pointer actual argument that | ||
| > corresponds to a nonoptional nonpointer dummy argument shall be pointer associated with | ||
| > a target. | ||
|
|
||
| This bug can lead to a runtime crash for models that use MPAS as a dynamical core | ||
| (e.g., CAM, CAM-SIMA). | ||
|
|
||
| Fix this issue by adding the `pointer` attribute to the `diag_physics` dummy argument | ||
| for the `atm_compute_dyn_tend` subroutine. | ||
| --- | ||
| src/core_atmosphere/dynamics/mpas_atm_time_integration.F | 2 +- | ||
| 1 file changed, 1 insertion(+), 1 deletion(-) | ||
|
|
||
| diff --git a/src/core_atmosphere/dynamics/mpas_atm_time_integration.F b/src/core_atmosphere/dynamics/mpas_atm_time_integration.F | ||
| index 238ca7235..c16072976 100644 | ||
| --- a/src/core_atmosphere/dynamics/mpas_atm_time_integration.F | ||
| +++ b/src/core_atmosphere/dynamics/mpas_atm_time_integration.F | ||
| @@ -5813,7 +5813,7 @@ module atm_time_integration | ||
| type (mpas_pool_type), intent(in) :: state | ||
| type (mpas_pool_type), intent(in) :: diag | ||
| type (mpas_pool_type), intent(in) :: mesh | ||
| - type (mpas_pool_type), intent(in) :: diag_physics | ||
| + type (mpas_pool_type), pointer, intent(in) :: diag_physics | ||
| type (mpas_pool_type), intent(in) :: configs | ||
| integer, intent(in) :: nVertLevels ! for allocating stack variables | ||
| integer, intent(in) :: rk_step, dynamics_substep | ||
| -- | ||
| 2.48.1 | ||
|
|
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I might make it clear that the heights listed here are (I assume) in meters: