Skip to content

Commit

Permalink
Declare additional array arguments as pointers for AQMv7 EE2 complia…
Browse files Browse the repository at this point in the history
…nce (use -check all)
  • Loading branch information
rmontuoro committed Nov 20, 2023
1 parent ef141ca commit d6563b5
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 23 deletions.
2 changes: 1 addition & 1 deletion physics/GFS_DCNV_generic_post.F90
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ subroutine GFS_DCNV_generic_post_run (im, levs, lssav, ldiag3d, qdiag3d, ras, &
logical, intent(in) :: satmedmf, trans_trac

real(kind=kind_phys), dimension(:), intent(inout) :: rainc, cldwrk
real(kind=kind_phys), dimension(:,:), intent(inout) :: upd_mf, dwn_mf, det_mf
real(kind=kind_phys), dimension(:,:), pointer :: upd_mf, dwn_mf, det_mf
real(kind=kind_phys), dimension(:,:), intent(inout) :: cnvw, cnvc

real(kind=kind_phys), dimension(:,:,:), pointer :: dtend
Expand Down
26 changes: 13 additions & 13 deletions physics/GFS_MP_generic_post.F90
Original file line number Diff line number Diff line change
Expand Up @@ -55,33 +55,33 @@ subroutine GFS_MP_generic_post_run(
real(kind=kind_phys), dimension(:,:), intent(in) :: prsi, phii
real(kind=kind_phys), dimension(:,:,:), intent(in) :: gq0, save_q

real(kind=kind_phys), dimension(:,:,:), intent(in) :: dfi_radar_tten
real(kind=kind_phys), dimension(:,:,:), pointer :: dfi_radar_tten

real(kind=kind_phys), dimension(:), intent(in ) :: sr
real(kind=kind_phys), dimension(:), intent(inout) :: rain, domr_diag, domzr_diag, domip_diag, doms_diag, tprcp, &
srflag, cnvprcp, totprcp, totice, totsnw, totgrp, cnvprcpb, &
totprcpb, toticeb, totsnwb, totgrpb, pwat
real(kind=kind_phys), dimension(:), intent(inout) :: rain_cpl, rainc_cpl, snow_cpl

real(kind=kind_phys), dimension(:,:,:), intent(inout) :: dtend
real(kind=kind_phys), dimension(:,:,:), pointer :: dtend
integer, dimension(:,:), intent(in) :: dtidx

! Stochastic physics / surface perturbations
real(kind=kind_phys), dimension(:), intent(inout) :: drain_cpl, dsnow_cpl

! Rainfall variables previous time step
integer, intent(in) :: lsm, lsm_ruc, lsm_noahmp
real(kind=kind_phys), dimension(:), intent(inout) :: raincprv
real(kind=kind_phys), dimension(:), intent(inout) :: rainncprv
real(kind=kind_phys), dimension(:), intent(inout) :: iceprv
real(kind=kind_phys), dimension(:), intent(inout) :: snowprv
real(kind=kind_phys), dimension(:), intent(inout) :: graupelprv
real(kind=kind_phys), dimension(:), intent(inout) :: draincprv
real(kind=kind_phys), dimension(:), intent(inout) :: drainncprv
real(kind=kind_phys), dimension(:), intent(inout) :: diceprv
real(kind=kind_phys), dimension(:), intent(inout) :: dsnowprv
real(kind=kind_phys), dimension(:), intent(inout) :: dgraupelprv
real(kind=kind_phys), dimension(:,:), intent(inout) :: dqdt_qmicro
real(kind=kind_phys), dimension(:), pointer :: raincprv
real(kind=kind_phys), dimension(:), pointer :: rainncprv
real(kind=kind_phys), dimension(:), pointer :: iceprv
real(kind=kind_phys), dimension(:), pointer :: snowprv
real(kind=kind_phys), dimension(:), pointer :: graupelprv
real(kind=kind_phys), dimension(:), pointer :: draincprv
real(kind=kind_phys), dimension(:), pointer :: drainncprv
real(kind=kind_phys), dimension(:), pointer :: diceprv
real(kind=kind_phys), dimension(:), pointer :: dsnowprv
real(kind=kind_phys), dimension(:), pointer :: dgraupelprv
real(kind=kind_phys), dimension(:,:), pointer :: dqdt_qmicro
real(kind=kind_phys), dimension(:,:), intent(inout) :: prevsq
real(kind=kind_phys), intent(in) :: dtp

Expand Down
2 changes: 1 addition & 1 deletion physics/GFS_SCNV_generic_post.F90
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ subroutine GFS_SCNV_generic_post_run (im, levs, nn, lssav, ldiag3d, qdiag3d, &
real(kind=kind_phys), dimension(:,:,:), intent(in) :: save_q, gq0

! dtend only allocated if ldiag3d == .true.
real(kind=kind_phys), intent(inout) :: dtend(:,:,:)
real(kind=kind_phys), pointer :: dtend(:,:,:)
integer, intent(in) :: dtidx(:,:)
integer, intent(in) :: index_of_temperature, index_of_x_wind, index_of_y_wind, index_of_process_scnv
real(kind=kind_phys), dimension(:,:,:), intent(in) :: clw
Expand Down
4 changes: 2 additions & 2 deletions physics/GFS_suite_interstitial_4.F90
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ subroutine GFS_suite_interstitial_4_run (im, levs, ltaerosol, tracers_total, ntr

! dtend and dtidx are only allocated if ldiag3d
logical, intent(in) :: ldiag3d, qdiag3d
real(kind=kind_phys), dimension(:,:,:), intent(inout) :: dtend
real(kind=kind_phys), dimension(:,:,:), pointer :: dtend
integer, dimension(:,:), intent(in) :: dtidx
integer, intent(in) :: index_of_process_conv_trans,ntk,ntke

Expand Down Expand Up @@ -290,4 +290,4 @@ subroutine GFS_suite_interstitial_4_run (im, levs, ltaerosol, tracers_total, ntr

end subroutine GFS_suite_interstitial_4_run

end module GFS_suite_interstitial_4
end module GFS_suite_interstitial_4
2 changes: 1 addition & 1 deletion physics/gfdl_cloud_microphys.F90
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ subroutine gfdl_cloud_microphys_run(
real(kind=kind_phys), intent(inout), dimension(:,:) :: rew, rei, rer, res, reg
logical, intent (in) :: cplchm
! ice and liquid water 3d precipitation fluxes - only allocated if cplchm is .true.
real(kind=kind_phys), intent(inout), dimension(:,:) :: pfi_lsan, pfl_lsan
real(kind=kind_phys), pointer , dimension(:,:) :: pfi_lsan, pfl_lsan

character(len=*), intent(out) :: errmsg
integer, intent(out) :: errflg
Expand Down
9 changes: 5 additions & 4 deletions physics/samfdeepcnv.f
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,10 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, &
logical, intent(in) :: first_time_step,restart,hwrf_samfdeep, &
& progsigma
real(kind=kind_phys), intent(in) :: nthresh
real(kind=kind_phys), intent(in) :: ca_deep(:)
real(kind=kind_phys), intent(in) :: sigmain(:,:),qmicro(:,:), &
& tmf(:,:),q(:,:), prevsq(:,:)
real(kind=kind_phys), pointer :: ca_deep(:)
real(kind=kind_phys), intent(in) :: sigmain(:,:), &
& q(:,:), prevsq(:,:)
real(kind=kind_phys), pointer :: qmicro(:,:), tmf(:,:)
real(kind=kind_phys), intent(out) :: rainevap(:)
real(kind=kind_phys), intent(out) :: sigmaout(:,:)
logical, intent(in) :: do_ca,ca_closure,ca_entr,ca_trigger
Expand All @@ -121,7 +122,7 @@ subroutine samfdeepcnv_run (im,km,first_time_step,restart, &
! GJF* These variables are conditionally allocated depending on whether the
! Morrison-Gettelman microphysics is used, so they must be declared
! using assumed shape.
real(kind=kind_phys), dimension(:,:), intent(inout) :: &
real(kind=kind_phys), dimension(:,:), pointer :: &
& qlcn, qicn, w_upi, cnv_mfd, cnv_dqldt, clcn &
&, cnv_fice, cnv_ndrop, cnv_nice, cf_upi
! *GJF
Expand Down
3 changes: 2 additions & 1 deletion physics/samfshalcnv.f
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ subroutine samfshalcnv_run(im,km,itc,ntc,cliq,cp,cvap, &
real(kind=kind_phys), intent(in) :: delt
real(kind=kind_phys), intent(in) :: psp(:), delp(:,:), &
& prslp(:,:), garea(:), hpbl(:), dot(:,:), phil(:,:), &
& qmicro(:,:),tmf(:,:),prevsq(:,:),q(:,:)
& prevsq(:,:),q(:,:)
real(kind=kind_phys), pointer :: qmicro(:,:),tmf(:,:)

real(kind=kind_phys), intent(in) :: sigmain(:,:)
!
Expand Down

0 comments on commit d6563b5

Please sign in to comment.