728x90
728x170
*[header][Multi-threading] mutex (C++11)
<mutex>
Mutex
It contains mutex types, lock types and specific functions:
- Mutex types are lockable types used to protect access to a critical section of code: locking a mutex prevents other threads from locking it (exclusive access) until it is unlocked: mutex, recursive_mutex, timed_mutex, recursive_timed_mutex.
- Locks are objects that manage a mutex by associating its access to their own lifetime: lock_guard, unique_lock.
- Functions to lock mutiple mutexes simultaneously (try_lock, lock) and to directly prevent concurrent execution of a specific function (call_once).
Classes
Mutexes
- mutex
- Mutex class (class )
- recursive_mutex
- Recursive mutex class (class )
- timed_mutex
- Timed mutex class (class )
- recursive_timed_mutex
- Recursive timed mutex (class )
Locks
- lock_guard
- Lock guard (class template )
- unique_lock
- Unique lock (class template )
Other types
- once_flag
- Flag argument type for call_once (class )
- adopt_lock_t
- Type of adopt_lock (class )
- defer_lock_t
- Type of defer_lock (class )
- try_to_lock_t
- Type of try_to_lock (class )
Functions
- try_lock
- Try to lock multiple mutexes (function template )
- lock
- Lock multiple mutexes (function template )
- call_once
- Call function once (public member function )
728x90
그리드형(광고전용)
'Programming > C++' 카테고리의 다른 글
[header][Input/Output] ios (0) | 2017.11.08 |
---|---|
[header][Input/Output] iomanip (0) | 2017.11.08 |
[header][Input/Output] fstream (0) | 2017.11.08 |
[header][Multi-threading] thread (C++11) (0) | 2017.11.08 |
[header][Multi-threading] future (C++11) (0) | 2017.11.08 |
[header][Multi-threading] condition_variable (C++11) (0) | 2017.11.08 |
[header][Multi-threading] atomic (C++11) (0) | 2017.11.08 |
[header][other] valarray (0) | 2017.11.08 |