OpendTect-6_4  6.4
Classes | Namespaces | Macros | Functions
atomic.h File Reference
Include dependency graph for atomic.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Threads::Atomic< T >
 
class  Threads::AtomicPointer< T >
 Atomic instantiated with a pointer. The class really only handles the casting from a void* to a T*. More...
 
class  Threads::SpinLock
 Is an alternative to Mutex. It is a lock which causes a thread trying to acquire it to simply wait in a loop ("spin") while repeatedly checking if the lock is available. Because they avoid overhead from operating system process re-scheduling or context switching, spinlocks are efficient if threads are only likely to be blocked for a short period. More...
 

Namespaces

 Threads
 interface to threads that should be portable.
 

Macros

#define __GCCATOMICS__
 
#define mAtomicPointerType   T*
 
#define mImplAtomicPointerOperator(func, op, ret)
 

Functions

bool Threads::atomicSetIfValueIs (volatile int &val, int curval, int newval, int *actualvalptr)
 

Macro Definition Documentation

#define __GCCATOMICS__
#define mAtomicPointerType   T*
#define mImplAtomicPointerOperator (   func,
  op,
  ret 
)
Value:
template <class T> inline \
T* AtomicPointer<T>::func \
{ \
mAtomicPointerType old = (mAtomicPointerType) ptr_.get(); \
\
while ( !ptr_.setIfValueIs( old, (mAtomicPointerType) (op), &old ) ) \
{} \
\
return ret; \
}
#define mAtomicPointerType
Definition: atomic.h:134

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2019