## shmem_wait_until

#### Purpose

Waits for a variable on the local processing element (PE) to change.

#### C syntax

    #include <shmem.h>

    void shmem_wait_until(long *var, int cond, long value);

#### Parameters

INPUT
ivar
  A remotely accessible integer variable that is being updated by a remote PE.
cond
  The compare operator that compares var with value. The following are the supported cond values:

  SHMEM_CMP_EQ Equal

  SHMEM_CMP_NE Not equal

  SHMEM_CMP_GT Greater then

  SHMEM_CMP_LE Less then or equal

  SHMEM_CMP_LT Less then operator

  SHMEM_CMP_GE Greater then or equal.

value
  The right operand of the compare operator cond. The left one is the value pointed by var.

#### Description

This function is used for point-to-point synchronization. It suspends the execution of the calling PE until the value of the symmetric variable var is changed

The function shmem_wait_until() blocks the calling PE until some remote PE changes the long variable var to satisfy the condition implied by comp and val.

#### C examples

#### Related information

Subroutines: shmem_put

OpenSHMEM API Index