Gentoo Archives: gentoo-dev

From: Jeff Adams <jbadams@×××××××××.com>
To: gentoo-dev@g.o
Subject: [gentoo-dev] What is the fastest mechanism for ipc communication under the gentoo-sources kernel
Date: Tue, 22 Jul 2003 17:07:47
Message-Id: FHEELGILKDENPLDMDNMJGEFODJAA.jbadams@intensifi.com
1 Hello,
2
3 I have a producer process that makes updates to shared memory. I need to
4 notify consumer processes (potentially multiple) as quickly as possible.
5
6 What I am looking for is a fast "wake-up" mechanism and a synchronization
7 mechanism so that events are not lost.
8
9 I'm currently using semaphores as the wake up mechanism. Question is this
10 the fastest way to do this without going into a tight loop (waste of
11 processor cycles)?
12
13 I'd also have the issue of clients showing up asynchronously. If I just use
14 semaphores counts based on the number of clients I run the risk of missing a
15 client. Also if the clients process events too slowly then the producer
16 will keep incrementing the semaphore beyond the client count. Then if one
17 client is faster than the others it may get awakened multiple times for the
18 same event.
19
20 Any suggestions?
21
22 Thanks in advance!
23
24
25
26
27 --
28 gentoo-dev@g.o mailing list

Replies