[cgl_discussion] Re: [cgl_specs] Support for asynchronous events
pkathail at cisco.com
Tue Nov 12 10:03:08 PST 2002
My understanding, from reading the requirements, is that you are looking
for asynchronous event delivery with priority queuing of events. At
surface this looks like a glorified method of delivering POSIX real-time signals. Is that what you want or am I missing something? If this
is what you want then, read-on?
In a multi-threaded system, I have found programming with asynchronous
events to be cumbersome and error prone. I think programming model becomes
simpler and more flexible, if you allow these events to be dropped into
a queue that can be watched/ queried by various threads. One or more
threads should be able to sleep on this queue and woken up when events
are delivered/ available in the queue. At the same time polling of queue
in the user space should be very efficient.
Multi-threaded processes can have one or more threads waiting on this
queue and processing the event as they arrive. Application will also
have choice of tuning the number of threads based on arrival rate of
events. Applications will be able to use normal locking primitives to
protect critical sections and data structures.
Single threaded applications should be able to poll the event on natural
protection boundaries or create a small stub thread, that drops appropriate
signal for processing thread to process the event.
At 11/8/2002 05:37 PM -0500, Frederic Rossi (LMC) wrote:
>During the OSDL F2F meeting in San Jose, support for asynchronous events
>in the Linux kernel was brought in FS1 - HA platform as part of the
>'new and wonderful features'.
>As a follow up, I am attaching a document that lists the requirements
>for the support of asynchronous events. It is a first draft and I would
>appreciate your feedback on it.
>The implementation is available for download at
>Peter: In case a conference call is needed to discuss this further,
>please arrange for it. I am ready to run a slide show and go through
>AE in details.
>Ericsson Research Canada frederic.rossi at ericsson.ca
>Systems Research LMC/UU Phone: (514) 345-7900 x5641
>8400 Decarie Blvd.
>Town of Mount Royal
>H4P 2N2, (Quebec) Canada
More information about the cgl_discussion