multilayer_state_enter_data_impl Subroutine

private subroutine multilayer_state_enter_data_impl(this)

Arguments

Type IntentOptional Attributes Name
type(multilayer_state_t), intent(inout) :: this

Called by

proc~~multilayer_state_enter_data_impl~~CalledByGraph proc~multilayer_state_enter_data_impl multilayer_state_enter_data_impl proc~multilayer_state_enter_data multilayer_state_t%multilayer_state_enter_data proc~multilayer_state_enter_data->proc~multilayer_state_enter_data_impl

Variables

Type Visibility Attributes Name Initial
integer, private :: it

Source Code

   subroutine multilayer_state_enter_data_impl(this)
      type(multilayer_state_t), intent(inout) :: this
      integer :: it

      !$acc enter data copyin(this%h_layer, this%h_layer0, &
      !$acc&                  this%u_face_x_layer, this%hu_face_x_layer, &
      !$acc&                  this%v_face_y_layer, this%hv_face_y_layer, &
      !$acc&                  this%u_face_x_layer0, this%v_face_y_layer0, &
      !$acc&                  this%u_av_layer, this%v_av_layer, this%h_av_layer, &
      !$acc&                  this%w_interface)
      !$acc enter data create(this%mass_flux_x_layer, this%mass_flux_y_layer, &
      !$acc&                  this%flux_h_layer)
      !$acc enter data copyin(this%p_top)
      !$acc enter data copyin(this%rho_layer, this%mass_budget_continuity, &
      !$acc&                  this%heat_budget_surface, this%salt_budget_surface, &
      !$acc&                  this%heat_budget_geothermal, &
      !$acc&                  this%heat_budget_sponge, this%salt_budget_sponge, &
      !$acc&                  this%heat_budget_vert_adv, this%salt_budget_vert_adv, &
      !$acc&                  this%heat_budget_vdiff, this%salt_budget_vdiff, &
      !$acc&                  this%heat_budget_hdiff, this%salt_budget_hdiff, &
      !$acc&                  this%heat_budget_horiz_adv, this%salt_budget_horiz_adv, &
      !$acc&                  this%mass_budget_remap, this%heat_budget_remap, &
      !$acc&                  this%salt_budget_remap, this%wet_mask)
      ! `copyin`, not `create`: the first-live-layer indices are filled
      ! on the HOST at configure (before this map) and never recomputed
      ! on device, so the seeded value has to travel with the map.
      !$acc enter data copyin(this%k_top, this%k_top_u, this%k_top_v)
      !$acc enter data copyin(this%k_bot, this%k_bot_u, this%k_bot_v)

      if (allocated(this%tracers)) then
         !$acc enter data copyin(this%tracers)
         do it = 1, size(this%tracers)
            !$acc enter data copyin(this%tracers(it)%hTr, &
            !$acc&                  this%tracers(it)%hTr0)
         end do
      end if

      this%registry_locked = .true.
   end subroutine multilayer_state_enter_data_impl