Board index » cppbuilder » Timers and interrupts: BCB5

Timers and interrupts: BCB5


2004-12-30 01:30:55 PM
cppbuilder97
How do you judge the precedence of timer events and other asynchronous
events? I have a server app that has several TCP and UDP sockets
receiving data all the time, and a couple of system timers that run at
100ms intervals.
The question is, if one of the timer routines gets very busy, will the
asynchronous reads from the network components have to wait or do they
take precedence? And if the receivers on all the sockets are really
busy, does the timer have to wait for an opening to run?
tia
Mike
 
 

Re:Timers and interrupts: BCB5

MikeKnoblock < XXXX@XXXXX.COM >wrote:
Quote

[...] does the timer have to wait for an opening to run?
Timers always have to wait.
Timers are message driven. When it's triggered, a message is
posted to the threads que. If you don't cause the messages to
be processed during a cpu intensive process, the timer won't
be executed until the block of code finishes.
You also probably need to manage seperate threads for
individual connections.
~ JD