Search Toolkit Book for CFutex
Wrapper around Linux's futex. More...
#include "srv_sync.hpp"
(Private to src/app/netcache
.)
Wrapper around Linux's futex.
Definition at line 140 of file srv_sync.hpp.
◆ EWaitResultType of result returned from WaitValueChange()
Enumerator eWaitWokenUpThread was woken up by call to WakeUpWaiters() from another thread.
eValueChangedFutex's value was changed in another thread before waiting was started.
eTimedOutMethod returned because total waiting time exceeded given timeout.
Definition at line 162 of file srv_sync.hpp.
◆ CFutex() [1/2] ◆ CFutex() [2/2] ◆ AddValue() int CFutex::AddValue ( int cnt_to_add ) inline ◆ ChangeValue() bool CFutex::ChangeValue ( int old_value, int new_value ) inlineAtomically change value of the futex.
If current futex value was changed in another thread and doesn't match old_value then method returns FALSE and value is not changed. Otherwise value is changed to new_value and method returns TRUE.
Definition at line 244 of file srv_sync.hpp.
References AtomicCAS(), and m_Value.
Referenced by CMiniMutex::TryLock().
◆ GetValue() int CFutex::GetValue ( void ) inline ◆ operator=() ◆ SetValueNonAtomic() void CFutex::SetValueNonAtomic ( int new_value ) inline ◆ WaitValueChange() [1/2] ◆ WaitValueChange() [2/2] ◆ WakeUpWaiters() int CFutex::WakeUpWaiters ( int cnt_to_wake ) ◆ m_Value volatile int CFutex::m_Value privateThe documentation for this class was generated from the following files:
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4