MSMPI_Waitsome_interruptible function

Waits until at least one of the operations that is associated with active handles in the list has finished, or the call is interrupted by another thread that calls MSMPI_Queuelock_acquire.

Syntax

int MPIAPI MSMPI_Waitsome_interruptible(
        int                                         incount,
        _Inout_count_(incount) MPI_Request          array_of_requests[],
  _Out_ int                                         *outcount,
        _Out_cap_post_count_(incount,*outcount) int array_of_indices[],
        _Out_cap_post_count_(incount,*outcount) int array_of_statuses[]
);

Parameters

  • incount
    The number of requests in the array array_of_requests.

  • array_of_requests
    Array of request handles of the operations on which to wait for completion. If a request handle was allocated by a nonblocking communication function, then it is deallocated, and the associated handle is set to MPI_REQUEST_NULL.

  • outcount [out]
    The number of requests that is specified in the array_of_requests parameter that are completed and the number of elements in the array_of_indices and array_of_statuses arrays.

    If the array_of_requests contains no active handles, then the function returns immediately with the outcount parameter set to MPI_UNDEFINED.

    If this function is interrupted before any requests are completed, then the call returns with the outcount parameter set to zero.

  • array_of_indices
    Returns the indices within the array_of_requests parameter of the operations that are completed. Array indexes are zero-based in C and one-based in Fortran.

  • array_of_statuses
    Returns the status of the operations that are completed. The elements of this array correspond to the elements of the array_of_indices array.

Return value

Returns MPI_SUCCESS on success. Otherwise, the return value is an error code.

In Fortran, the return value is stored in the IERROR parameter.

If the function returns an error other than MPI_ERR_IN_STATUS, it does not update the error fields of the statuses in the array_of_statuses parameter.

Remarks

In a multi-threaded environment, users must obtain the global Microsoft MPI lock by using the MSMPI_Queuelock_acquire function before they call MSMPI_Waitsome_interruptible. This function is interrupted when another thread calls the MSMPI_Queuelock_acquire function in order to access the MPI library.

This function is an extension to the standard.

Requirements

Product

HPC Pack 2012 MS-MPI Redistributable Package, HPC Pack 2008 R2 MS-MPI Redistributable Package, HPC Pack 2008 MS-MPI Redistributable Package or HPC Pack 2008 Client Utilities

Header

Mpi.h

Library

Msmpi.lib

DLL

Msmpi.dll

See also

MPI Point to Point Functions

MSMPI_Lock_queue

MSMPI_Queuelock_acquire

MSMPI_Queuelock_release

MPI_Waitsome