Re: IPC (process to multi-process)
- From: Dances With Crows <danSPANceswitTRAPhcrows@xxxxxxxxx>
- Date: Fri, 09 Feb 2007 09:58:42 -0600
On 7 Feb 2007 04:27:26 -0800, lm0309@xxxxxxxxx staggered into the Black
Sun and said:
Dances With Crows wrote:
lm0309@xxxxxxxxx wrote:
open the socket /dev/lircd for writing. lircd then reads informationIf I understand correctly, this mechanims provides "broadcast"
from various remote controls and writes the info that it receives to
the socket.
capability [where] every process needs to filter out messages not
belonging to it. I'm intersted in "multicasting" capability.
"Multicasting" as used for IP is a red herring if all the processes are
on the same machine. Don't use that term if it doesn't apply; it'll
just confuse people.
What is it that you're trying to do? Details Count; you've beenI need more ideas to solve the problem (it is a small embedded system
pretty vague so far.
where all the processes [are] located on the same host).
This is *still* too vague to do much with. What are the processes
doing? What is the bottleneck, CPU speed or I/O speed? Did you write
the code yourself, did you get the code from somewhere else, can you
modify the code reasonably easily? The answers to those questions will
dictate what you do.
If the processes are on the same machine, why wouldn't sockets work?
If the processes are all on the same machine, local sockets are probably
the fastest IPC mechanism you're going to get. If you have events of
multiple types, you might have the server process open multiple sockets,
and send A events to /tmp/socketA , B events to /tmp/socketB , etcetera.
Or possibly POSIX shared memory may be easier to use in this case.
There, you'd just shm_open() an object in various processes, then mmap()
that object and read/write things via the void* you get back. This may
introduce synchronization problems if multiple processes are reading and
writing to the same segment, so you may want multiple shared memory
segments. Without more info on what it is that you're doing, it'll be
impossible to speak in any but the most general terms about what you
need to do here. HTH anyway,
--
I have had to deal with kangaroos, donkeys, cows, wild pigs
and some press leaks by former Vice President Cheney.
--MegaHAL, trained on ASR
Matt G|There is no Darkness in Eternity/But only Light too dim for us to see
.
- References:
- IPC (process to multi-process)
- From: lm0309
- Re: IPC (process to multi-process)
- From: Dances With Crows
- Re: IPC (process to multi-process)
- From: lm0309
- Re: IPC (process to multi-process)
- From: Dances With Crows
- Re: IPC (process to multi-process)
- From: lm0309
- IPC (process to multi-process)
- Prev by Date: Re: Which Windows and Mac fonts are seen by Linux users?
- Next by Date: Question on configuration.
- Previous by thread: Re: IPC (process to multi-process)
- Next by thread: gphoto/digicam alternatives
- Index(es):
Relevant Pages
|