Skip to content

Conversation

hertneky
Copy link
Collaborator

@hertneky hertneky commented Mar 27, 2025

This PR syncs NCAR/main up with changes from the ufs/dev branch

ufs/dev PR#246

fv3atm PR#914

ccpp-scm PR#578

@@ -1838,11 +1865,10 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, &
val = 1.e-4
if (wc(i) < val) cnvflg(i)=.false.
endif
enddo
enddo
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
enddo
enddo

@@ -2929,10 +2955,9 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, &
advfac(i) = min(advfac(i), 1.)
endif
enddo

Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change

dimensions = (horizontal_loop_extent,vertical_layer_dimension)
type = real
kind = kind_phys
intent = out
Copy link
Collaborator

Choose a reason for hiding this comment

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

omegaout is only modified if certain conditions are met:

if(((imfshalcnv == imfshalcnv_samf) .or. (imfdeepcnv == imfdeepcnv_samf) &
          .or. (imfshalcnv == imfshalcnv_c3) .or. (imfdeepcnv == imfdeepcnv_c3)) &
          .and. progomega)then

Therefore, this variable must be intent(inout)?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Or is the variable allocated only under these conditions? Then it would make sense to test for the variable being allocated instead of the if test in the code (@dustinswales)?

Copy link
Collaborator

Choose a reason for hiding this comment

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

@climbfuji Good catch. A similar issue was discussed and addressed in ufs-community@43807e6, but this one was missed. It looks like this is a metadata error only, though.

Copy link
Collaborator

Choose a reason for hiding this comment

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

@grantfirl it looks like I missed this one in the meta file. I'm ok with changing it to inout.

Copy link
Collaborator

Choose a reason for hiding this comment

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

OK, done. I'll figure out a way to get the fix back into ufs/dev.

Copy link
Collaborator

Choose a reason for hiding this comment

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

thank you! I'm happy to try to do so as well. It should not require new baselines as progomega is false. (Although those highly optimized -DFASTER tests might...)

Copy link
Collaborator

Choose a reason for hiding this comment

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

@lisa-bengtsson I think that it can be added to ufs-community#248 without ill effect. It's quasi-related anyway.

@grantfirl grantfirl merged commit addf7c6 into NCAR:main Mar 31, 2025
3 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.

6 participants