About 137,000 results
Open links in new tab
  1. std::mutex - cppreference.com

    Mar 6, 2024 · The mutex class is a synchronization primitive that can be used to protect shared data from being simultaneously accessed by multiple threads. mutex offers exclusive, non …

  2. multithreading - What is a mutex? - Stack Overflow

    Aug 29, 2008 · A mutex is a programming concept that is frequently used to solve multi-threading problems. My question to the community: What is a mutex and how do you use it?

  3. std::lock_guard - cppreference.com

    Apr 21, 2025 · The class lock_guard is a mutex wrapper that provides a convenient RAII-style mechanism for owning a mutex for the duration of a scoped block. When a lock_guard object …

  4. What is the difference between lock, mutex and semaphore?

    Jun 14, 2021 · I've heard these words related to concurrent programming, but what's the difference between lock, mutex and semaphore?

  5. std::future - cppreference.com

    Mar 12, 2024 · The class template std::future provides a mechanism to access the result of asynchronous operations: An asynchronous operation (created via std::async, …

  6. Difference between binary semaphore and mutex - Stack Overflow

    Is there any difference between a binary semaphore and mutex or are they essentially the same?

  7. std::unique_lock - cppreference.com

    Apr 21, 2025 · The class unique_lock is a general-purpose mutex ownership wrapper allowing deferred locking, time-constrained attempts at locking, recursive locking, transfer of lock …

  8. What makes the boost::shared_mutex so slow - Stack Overflow

    Jun 26, 2019 · The thread that has been awoken now "owns" the lock. Rinse wash and repeat. Shared Mutex A shared mutex takes this concept a step further. It can be owned by a single …

  9. std::call_once - cppreference.com

    Oct 22, 2023 · Executes the Callable object f exactly once, even if called concurrently from several threads. In detail: If, by the time std::call_once is called, flag indicates that f was …

  10. understanding of pthread_cond_wait() and pthread_cond_signal()

    Jan 3, 2024 · Now in thread 2, after pthread_cond_signal() is called, pthread_mutex_unlock(&mutex) is going to run, it seems to me that it wants to unlock a the …