Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
fe93817
Initial commit
dustinswales Jul 29, 2025
feabe8c
Some changes to physics scheme metadata
dustinswales Jul 29, 2025
ce99167
Revert some changes
dustinswales Jul 29, 2025
e44d0d2
Update ccpp_driver logic
dustinswales Jul 29, 2025
c079d4e
Revert "Update ccpp_driver logic"
dustinswales Jul 29, 2025
0ee249c
Fix typo in physics metadata
dustinswales Jul 29, 2025
a66c10b
Cleanup whitespace changes
dustinswales Jul 30, 2025
d8b5962
Some small changes. Running now
dustinswales Jul 31, 2025
01b61fe
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into fea…
dustinswales Aug 6, 2025
2256bef
Update framework hash
dustinswales Aug 7, 2025
27a8509
Sync physics
dustinswales Aug 18, 2025
5049c52
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into fea…
dustinswales Aug 18, 2025
cc0638e
Update framework hash
dustinswales Aug 21, 2025
4170e6b
Update .gitmodules
dustinswales Aug 21, 2025
9044c70
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into fea…
dustinswales Aug 27, 2025
50e7e1a
Update physics
dustinswales Sep 8, 2025
ea4b896
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into fea…
dustinswales Sep 8, 2025
51181af
Move interstitial needed by radiation into different data container.
dustinswales Sep 8, 2025
0f8456b
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into HEAD
dustinswales Sep 8, 2025
7422b8b
Addline removed during merge conflict
dustinswales Sep 8, 2025
346727b
Revert incorrect ccpp framework hash
dustinswales Sep 8, 2025
4b457b4
Sync physics
dustinswales Sep 15, 2025
e2f14cd
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into HEAD
dustinswales Sep 15, 2025
225a765
Updated physics
dustinswales Sep 19, 2025
85e45e0
Merge branch 'develop' of https://github.com/NOAA-EMC/fv3atm into HEAD
dustinswales Sep 19, 2025
e526aac
Merge branch 'develop' into feature/ccpp_framework_update
grantfirl Oct 3, 2025
437e17c
Merge branch 'develop' into feature/ccpp_framework_update
grantfirl Nov 5, 2025
ab2295e
Merge branch 'develop' into feature/ccpp_framework_update
grantfirl Nov 7, 2025
e3754fe
Merge branch 'develop' into feature/ccpp_framework_update
grantfirl Nov 10, 2025
964091c
update MPAS code to follow PR#1006 changes to FV3
grantfirl Nov 11, 2025
152db86
update ccpp physics after merge
grantfirl Nov 13, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 25 additions & 30 deletions ccpp/CCPP_driver.F90
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ subroutine CCPP_step (step, nblks, ierr, dycore)
integer, intent(out) :: ierr
character(len=*), intent(in) :: dycore
! Local variables
integer :: nb, nt, ntX
integer :: nb, nt
integer :: ierr2
integer :: kdt_iau
logical :: iauwindow_center
Expand Down Expand Up @@ -216,11 +216,10 @@ subroutine CCPP_step (step, nblks, ierr, dycore)

!$OMP parallel num_threads (nthrds) &
!$OMP default (none) &
!$OMP shared (nblks, nthrdsX, non_uniform_blocks, &
!$OMP cdata_block, ccpp_suite, step, &
!$OMP GFS_Control, GFS_Interstitial, &
!$OMP dycore) &
!$OMP private (nb, nt, ntX, ierr2) &
!$OMP shared (nblks, cdata_block, ccpp_suite, &
!$OMP step, GFS_Control, GFS_Interstitial,&
!$OMP dycore) &
!$OMP private (nb, nt, ierr2) &
!$OMP reduction (+:ierr)
#ifdef _OPENMP
nt = omp_get_thread_num()+1
Expand All @@ -229,66 +228,61 @@ subroutine CCPP_step (step, nblks, ierr, dycore)
#endif
!$OMP do schedule (dynamic,1)
do nb = 1,nblks
! For non-uniform blocks/chunks, the last block/chunk has a different (shorter)
! length than the other blocks/chunks; use special CCPP_Interstitial(nthrdsX)
if (non_uniform_blocks .and. nb==nblks) then
ntX = nthrdsX
else
ntX = nt
end if
! Allocate physics interstitals for current thread
call GFS_Interstitial(nt)%create(ixs=GFS_control%chunk_begin(nb), ixe=GFS_control%chunk_end(nb), model=GFS_control)
!--- Call CCPP radiation/physics/stochastics group
if (trim(step)=="physics") then
if (trim(dycore)=="fv3") then
! Reset GFS_Interstitial DDT fields for this thread
call GFS_Interstitial(ntX)%reset(GFS_control)
call GFS_Interstitial(nt)%reset(GFS_control)
! Process-split physics
call ccpp_physics_run(cdata_block(nb,ntX), suite_name=trim(ccpp_suite), group_name="phys_ps", ierr=ierr2)
call ccpp_physics_run(cdata_block(nb,nt), suite_name=trim(ccpp_suite), group_name="phys_ps", ierr=ierr2)
if (ierr2/=0) then
write(0,'(2a,3(a,i4),a)') "An error occurred in ccpp_physics_run for group ", "phys_ps", &
", block/chunk ", nb, " and thread ", nt, " (ntX=", ntX, "):"
write(0,'(a)') trim(cdata_block(nb,ntX)%errmsg)
", block/chunk ", nb, " and thread ", nt, " (nt=", nt, "):"
write(0,'(a)') trim(cdata_block(nb,nt)%errmsg)
ierr = ierr + ierr2
endif
! Time-split physics
call ccpp_physics_run(cdata_block(nb,ntX), suite_name=trim(ccpp_suite), group_name="phys_ts", ierr=ierr2)
call ccpp_physics_run(cdata_block(nb,nt), suite_name=trim(ccpp_suite), group_name="phys_ts", ierr=ierr2)
if (ierr2/=0) then
write(0,'(2a,3(a,i4),a)') "An error occurred in ccpp_physics_run for group ", "phys_ts", &
", block/chunk ", nb, " and thread ", nt, " (ntX=", ntX, "):"
write(0,'(a)') trim(cdata_block(nb,ntX)%errmsg)
", block/chunk ", nb, " and thread ", nt, " (nt=", nt, "):"
write(0,'(a)') trim(cdata_block(nb,nt)%errmsg)
ierr = ierr + ierr2
endif
endif
if (trim(dycore)=="mpas") then
! Physics
call ccpp_physics_run(cdata_block(nb,ntX), suite_name=trim(ccpp_suite), group_name="physics", ierr=ierr2)
call ccpp_physics_run(cdata_block(nb,nt), suite_name=trim(ccpp_suite), group_name="physics", ierr=ierr2)
if (ierr2/=0) then
write(0,'(2a,3(a,i4),a)') "An error occurred in ccpp_physics_run for group ", "physics", &
", block/chunk ", nb, " and thread ", nt, " (ntX=", ntX, "):"
write(0,'(a)') trim(cdata_block(nb,ntX)%errmsg)
", block/chunk ", nb, " and thread ", nt, " (nt=", nt, "):"
write(0,'(a)') trim(cdata_block(nb,nt)%errmsg)
ierr = ierr + ierr2
endif
endif
else
if (trim(step)=="radiation") then
! Reset GFS_Interstitial DDT fields for this thread
call GFS_Interstitial(ntX)%reset(GFS_control)
call GFS_Interstitial(nt)%reset(GFS_control)
endif
! Radiation
call ccpp_physics_run(cdata_block(nb,ntX), suite_name=trim(ccpp_suite), group_name=trim(step), ierr=ierr2)
call ccpp_physics_run(cdata_block(nb,nt), suite_name=trim(ccpp_suite), group_name=trim(step), ierr=ierr2)
if (ierr2/=0) then
write(0,'(2a,3(a,i4),a)') "An error occurred in ccpp_physics_run for group ", trim(step), &
", block/chunk ", nb, " and thread ", nt, " (ntX=", ntX, "):"
write(0,'(a)') trim(cdata_block(nb,ntX)%errmsg)
", block/chunk ", nb, " and thread ", nt, " (nt=", nt, "):"
write(0,'(a)') trim(cdata_block(nb,nt)%errmsg)
ierr = ierr + ierr2
endif
! Microphysics (MPAS only)
if (trim(step)=="microphysics") then
if (trim(dycore)=="mpas") then
call ccpp_physics_run(cdata_block(nb,ntX), suite_name=trim(ccpp_suite), group_name="microphysics", ierr=ierr2)
call ccpp_physics_run(cdata_block(nb,nt), suite_name=trim(ccpp_suite), group_name="microphysics", ierr=ierr2)
if (ierr2/=0) then
write(0,'(2a,3(a,i4),a)') "An error occurred in ccpp_physics_run for group ", "microphysics", &
", block/chunk ", nb, " and thread ", nt, " (ntX=", ntX, "):"
write(0,'(a)') trim(cdata_block(nb,ntX)%errmsg)
", block/chunk ", nb, " and thread ", nt, " (nt=", nt, "):"
write(0,'(a)') trim(cdata_block(nb,nt)%errmsg)
ierr = ierr + ierr2
endif
else
Expand All @@ -297,6 +291,7 @@ subroutine CCPP_step (step, nblks, ierr, dycore)
endif
endif
endif
call GFS_Interstitial(nt)%destroy(GFS_control)
end do
!$OMP end do

Expand Down
1 change: 1 addition & 0 deletions ccpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ endif()
#------------------------------------------------------------------------------
# Build CCPP framework and physics

set(BUILD_SHARED_LIBS OFF)
add_subdirectory(framework)
add_subdirectory(physics)

Expand Down
Loading