Scatter integer data from root node (array of rank 3)
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(inout) | :: | array(:,:,:) |
local array for getting data |
||
| integer, | intent(in) | :: | localcount |
localcount elements will be fetched from the root node |
||
| integer, | intent(inout) | :: | rootglobalarray(:,:,:) |
array on the root node from which data will be sent |
||
| integer, | intent(in) | :: | counts(0:) |
how data should be partitioned, see MPI documentation or function comms_array_split |
||
| integer, | intent(in) | :: | displs(0:) | |||
| type(w90_error_type), | intent(out), | allocatable | :: | error | ||
| type(w90_comm_type), | intent(in) | :: | comm |
subroutine comms_no_sync_scatterv_int_3(array, localcount, rootglobalarray, counts, displs, error, comm) !! Scatter integer data from root node (array of rank 3) implicit none integer, intent(inout) :: array(:, :, :) !! local array for getting data integer, intent(in) :: localcount !! localcount elements will be fetched from the root node integer, intent(inout) :: rootglobalarray(:, :, :) !! array on the root node from which data will be sent integer, intent(in) :: counts(0:) !! how data should be partitioned, see MPI documentation or function comms_array_split integer, intent(in) :: displs(0:) type(w90_comm_type), intent(in) :: comm type(w90_error_type), allocatable, intent(out) :: error #ifdef W90_MPI integer :: ierr call mpi_scatterv(rootglobalarray, counts, displs, MPI_INTEGER, array, localcount, & MPI_INTEGER, root_id, comm%comm, ierr) if (ierr .ne. MPI_SUCCESS) then call set_base_error(error, 'Error in comms_scatterv_int_3', code_mpi) return end if #else !call my_icopy(localcount, rootglobalarray, 1, array, 1) array = rootglobalarray #endif end subroutine comms_no_sync_scatterv_int_3