Subj : Re: thread control by mutex, predicates and conditions puzzle To : comp.programming.threads From : roland Date : Fri Jan 07 2005 07:36 pm Jomu wrote: > What is this stop/start action thing? Do you want to freeze your > threads only at some points or wherever they happen to be when you stop > them? Say, your thread is blocking on IO. Now an external thread that is in charge of master control needs to tell: quit and restart IO. But I do not want to cancel the entire thread! (Imagine I have other valuable state information in my thrad.) How should I go for it when I 1) want a single thread wide master control while still be able to wait on different things during the threads lifetime 2) _and_ write code with portability in mind? (The IO clearly is highly system dependant.) I would be very glad if you could point me to such a pattern, since I am too a bit concerned of the "thundering herd" problem my broadcast could cause. Roland .