View Single Post
  #22   Spotlight this post!  
Unread 13-06-2010, 09:10
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: no control of bot when kicker is operating

Some thoughts for discussion:

Threads in C++ can be preemptive, regardless of whether or not they are created by the Notifier class. In any case, using cooperative multitasking techniques like releasing the CPU to service other tasks while waiting for an event or timer (block waiting) is good programming practice. It makes your code more responsive and avoids wasting CPU resources.

If the kicker code is properly implemented as a state machine, you don't need concurrency, and you don't need to worry about synchronization.

~

Last edited by Ether : 13-06-2010 at 10:00.