waitall_stat Subroutine

private subroutine waitall_stat(count, requests, status)

A routine to wait for all count communications, given by the message handles in requests, to complete. We return the message statuses

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: count
integer, intent(inout), dimension(:) :: requests
integer, intent(out), dimension(mp_status_size,count) :: status

Contents

Source Code


Source Code

  subroutine waitall_stat (count, requests, status)
    implicit none
    integer, intent(in) :: count
    integer, dimension(:), intent (inout) :: requests
    integer, dimension(mp_status_size,count), intent(out) :: status
# ifdef MPI
    !Note mpi_wait will set the request handle to MPI_NULL (or similar)
    !when message complete so have to set requests as inout
    integer :: ierror
!$OMP MASTER
    call time_message(.false., time_mp_sync, ' MPI Sync')
!$OMP END MASTER
    call mpi_waitall(count,requests,status,ierror)
!$OMP MASTER
    call time_message(.false., time_mp_sync, ' MPI Sync')
!$OMP END MASTER
# else
    UNUSED_DUMMY(count); UNUSED_DUMMY(requests)
    status = 0
# endif
  end subroutine waitall_stat