shallow thoughts on SHM
Hal Murray
hmurray at megapathdsl.net
Sun Oct 27 03:24:14 UTC 2019
> I do not have access to a copy of POSIX and the SuSv2 seems to have SHM
> support.
You can probably get what you need from man pages. Try man shm_overview
System V shared memory (shmget(2), shmop(2), etc.) is an older shared
memory API. POSIX shared memory provides a simpler, and better
designed interface; on the other hand POSIX shared memory is somewhat
less widely available (especially on older systems) than System V
shared memory.
I'd be happy to switch to POSIX SHM, but the current code works so I don't see
any point in doing that until we decide what else to do in this area.
Linux, NetBSD, and FreeBSD all support POSIX SHM. How many other OSes to we
currently support? Can somebody see if they have shm_open?
----------
> Up to six bits for the version another
You are worrying about the weeds when we haven't even found the forest yet.
----------
> Changing it to use say a UNIX socket would allow for simpler packet
> design.
That approach is worth investigating, but it adds a layer of complexity if you
want to support more than a single reader.
Why do you think it is simpler to design a packet than a memory layout. When
I want to send something like this over a network connection, I build it in
memory, then call send() or one of its friends.
--
These are my opinions. I hate spam.
More information about the devel
mailing list