GNU Radio 3.3.0 C++ API
read_trylock.h File Reference
#include "sync_utils.h"
#include "mutex.h"
Include dependency graph for read_trylock.h:

Go to the source code of this file.

Functions

static __inline int _read_trylock (eaddr_t ea)

Function Documentation

static __inline int _read_trylock ( eaddr_t  ea) [static]

read_trylock - acquire a reader lock, or return immediately. : handle to effective address of lock variable.

Acquire a non-exclusive reader lock, or return immediately. The only restriction here is that must be word aligned.

Returns 1 on success, or 0 on failure.

Context: The application should not call this interface from a tight loop!! Use read_lock() instead.

References DECL_MUTEX_VARS, and RAW_TEST_AND_SET.