MSMPI_Queuelock_acquire function

Acquires the Microsoft MPI library global lock. The lock queue is a First-In-First-Out (FIFO) queue.

Syntax

void MSMPI_Queuelock_acquire(
  _Out_ MSMPI_Lock_queue *queue
);

Parameters

  • queue [out]
    Points to a user-supplied MSMPI_Lock_queue structure that represents the position of the calling thread in the queue until the user releases the lock by using the MSMPI_Queuelock_release function.

Return value

This function does not return a value.

Remarks

The behavior of this function depends on the level of thread support in use. When the thread support is MPI_THREAD_SERIALIZED or lower, this function acquires the Microsoft MPI global lock, which provides FIFO serialization of callers and interrupts any MSMPI_Waitsome_interruptible function calls that are in-progress.

Applications should normally allocate the queue structure on the stack each time they acquire the lock.

To avoid errors when threads use MSMPI_Waitsome_interruptible in multi-threaded applications, all threads must acquire the global lock before they call MPI functions.

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_release

MSMPI_Waitsome_interruptible