about selecting the thread to wake up
how to avoid waking up the thread that are not safe enough (which will cause deadlock)?
|
You can't, AFAIK. That's kernel job to wake a thread.
Well, you need to add extra semaphores to make sure there are no deadlocks. It's not always easy, but that's the only way I know. |
All times are GMT -5. The time now is 07:28 AM. |