halo_sync_buffers_cleanup_3d Subroutine

public subroutine halo_sync_buffers_cleanup_3d()

Release the persistent 3D halo buffers. Idempotent.

Arguments

None

Called by

proc~~halo_sync_buffers_cleanup_3d~~CalledByGraph proc~halo_sync_buffers_cleanup_3d halo_sync_buffers_cleanup_3d proc~halo_sync_buffers_ensure_3d halo_sync_buffers_ensure_3d proc~halo_sync_buffers_ensure_3d->proc~halo_sync_buffers_cleanup_3d proc~halo_exchange_3d_device halo_exchange_3d_device proc~halo_exchange_3d_device->proc~halo_sync_buffers_ensure_3d

Source Code

   subroutine halo_sync_buffers_cleanup_3d()
      !! Release the persistent 3D halo buffers.  Idempotent.
      if (.not. allocated(hs3_buf_send_west)) return

      !$acc exit data delete(hs3_buf_send_west, hs3_buf_recv_west, &
      !$acc&                 hs3_buf_send_east, hs3_buf_recv_east, &
      !$acc&                 hs3_buf_send_south, hs3_buf_recv_south, &
      !$acc&                 hs3_buf_send_north, hs3_buf_recv_north)
      deallocate (hs3_buf_send_west, hs3_buf_recv_west)
      deallocate (hs3_buf_send_east, hs3_buf_recv_east)
      deallocate (hs3_buf_send_south, hs3_buf_recv_south)
      deallocate (hs3_buf_send_north, hs3_buf_recv_north)

      hs3_nghost = 0
      hs3_nx_total = 0
      hs3_ny_total = 0
      hs3_nz_capacity = 0

   end subroutine halo_sync_buffers_cleanup_3d