Re: using shared memory in Performer

New Message Reply Date view Thread view Subject view Author view

Simon Bennett (simonb++at++wormald.COM.AU)
Wed, 13 Sep 1995 10:41:23 +1000 (EST)


On Tue, 12 Sep 1995, Anita Kishore wrote:

> Is it possible to have any type of conflict between the shared arena of
> Performer and other shared arenas obtained by "shmat" and "shmget" inside
> a Performer application? There seems to be a time lag between when the data
> is written in (non-performer) shared arena and reading from it. The reading
> is done inside Performer.

There certainly is! For starters "shmat" and "shmget" are not IRIX arena
IPC calls, but System V IPC calls... The two IPC paradigm's don't co-exist
that happily. In addition the System V IPC calls are significantly slower
and don't seem to be MP safe. Unless you really need to use Sys V IPC, I'd
advise using IRIS arena memory with Performer applications, it's a much
happier solution. You can use arena's either directly through IRIX (see the
manpages for usinit et al) or through Performer - pfDataPools etc...

From the "IRIX System Programming Guide"

-- begin --

Types of Inter-Process Communication Available

IRIX supports several types of IPC. Standard AT&T System V Release 4 IPC is
available for making code portable. However, its implementation is
fundamentally different from (and slower than) that of the IRIX-specific IPC
also provided with IRIX. BSD socket-based IPC is supported for compatibility
and, to allow IPC across a network, between processes running on different
machines.

Do not mix the various types of IPC in a given program. Use System V IPC¾
based on a mechanism called keys¾for code that must comply with the MIPS
ABI, code that needs to be portable, or code that you're porting from another
System V operating system. Use arena-based IRIX IPC for applications that
require speed, ease of implementation, or multiprocessing ability. Socket-based
IPC is necessary only for code being ported from or to a BSD system, and for
network IPC.
-- end --

Hope this helps...

+----------------------------------------------------------------------------+
  Simon Bennett simonb++at++wormald.com.au
  Wormald Technology Advanced Systems Engineering Ph: +61 2 9981 0611 (x512)

          Meeting - an event where you take minutes and waste hours.


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:51:52 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.