python (65.2k questions)
javascript (44.3k questions)
reactjs (22.7k questions)
java (20.8k questions)
c# (17.4k questions)
html (16.3k questions)
r (13.7k questions)
android (13k questions)
Producer and Consumer Problem waiting threads
I tried to code Producer and Consumer Problem but after producing up to a certain value -(val) produce thread ends. but the consumer thread's condition variable waiting for notification but there is n...
VEMBU KARTHICK T
Votes: 0
Answers: 1
Accurate timer based processing implementation using condition variable
I need a thread to perform processing every one second accurately. Suppose if the worker thread is busy on some operation that takes more than one second, I want the worker thread to miss the 1s expir...
Raja Narayan
Votes: 0
Answers: 1
Why does std::condition_variable wait() require a std::unique_lock arg?
My thread does not need to be locked. std::unique_lock locks thread on construction. I am simply using cond_var.wait() as a way to avoid busy waiting. I have essentially circumvented the auto-locking ...
Chris Kouts
Votes: 0
Answers: 1
How to wake up multiple threads using condition variable
I want to run multiple threads every 100ms. In order to achieve that I thought of introducing std::mutex and std::condition_variable. The problem I'm facing is on what basis the threads should go into...
Harry
Votes: 0
Answers: 1