ice_ocean_brine_flux_impl Subroutine

private pure subroutine ice_ocean_brine_flux_impl(Q_salt, salt_flux_diag, Q_salt_const, nx, ny)

Full-array overwrite (including ghosts — they get Q_salt_const + 0, the same value the configure-time seed already gave them, so this is a no-op there). Explicit-shape dummies + decl-order (integer dims before the arrays that use them) so NVHPC stdpar compiles a device kernel against static bounds. Runs on the device-resident Q_salt (mapped by sf%enter_data) and salt_flux_diag (mapped by ice%enter_data).

Arguments

Type IntentOptional Attributes Name
real(kind=wp), intent(inout) :: Q_salt(nx,ny)
real(kind=wp), intent(in) :: salt_flux_diag(nx,ny)
real(kind=wp), intent(in) :: Q_salt_const
integer, intent(in) :: nx
integer, intent(in) :: ny

Called by

proc~~ice_ocean_brine_flux_impl~~CalledByGraph proc~ice_ocean_brine_flux_impl ice_ocean_brine_flux_impl proc~ice_ocean_brine_flux ice_ocean_brine_flux proc~ice_ocean_brine_flux->proc~ice_ocean_brine_flux_impl proc~engine_step_ice engine_step_ice proc~engine_step_ice->proc~ice_ocean_brine_flux proc~driver_run_ocean driver_run_ocean proc~driver_run_ocean->proc~engine_step_ice proc~rdb_ocean_step rdb_ocean_step proc~rdb_ocean_step->proc~engine_step_ice proc~driver_run driver_run proc~driver_run->proc~driver_run_ocean

Variables

Type Visibility Attributes Name Initial
integer, private :: i
integer, private :: j

Source Code

   pure subroutine ice_ocean_brine_flux_impl(Q_salt, salt_flux_diag, Q_salt_const, nx, ny)
      !! Full-array overwrite (including ghosts — they get
      !! `Q_salt_const + 0`, the same value the configure-time seed
      !! already gave them, so this is a no-op there). Explicit-shape
      !! dummies + decl-order (integer dims before the arrays that use
      !! them) so NVHPC stdpar compiles a device kernel against static
      !! bounds. Runs on the device-resident `Q_salt` (mapped by
      !! `sf%enter_data`) and `salt_flux_diag` (mapped by `ice%enter_data`).
      integer, intent(in) :: nx, ny
      real(wp), intent(inout) :: Q_salt(nx, ny)
      real(wp), intent(in) :: salt_flux_diag(nx, ny)
      real(wp), intent(in) :: Q_salt_const
      integer :: i, j

      do concurrent(j=1:ny, i=1:nx)
         Q_salt(i, j) = Q_salt_const + salt_flux_diag(i, j)
      end do
   end subroutine ice_ocean_brine_flux_impl