shm(5) shm(5)
NAME
shm - shared memory facility
SYNOPSIS
#include <sys/shm.h>
DESCRIPTION
The <sys/shm.h> header defines the following symbolic constants and
structure:
Symbolic constants:
SHMRDONLY Attach read-only (else read-write).
SHMLBA Segment low boundary address multiple.
SHMRND Round attach address to SHMLBA.
The following data types are defined through typedef:
shmattt Unsigned integer used for the number of current
attaches that must be able to store values at least as
large as a type unsigned short.
The structure shmidds contains the following members:
struct ipcperm shmperm Operation permission structure.
int shmsegsz Size of segment in bytes.
pidt shmlpid Process ID of last shared memory
operation.
pidt shmcpid Process ID of creator.
shmattt shmnattch Number of current attaches.
timet shmatime Time of last shmat().
timet shmdtime Time of last shmdt().
timet shmctime Time of last change by shmctl().
The pidt, timet, keyt and sizet types are defined as described in
<sys/types.h>. The following are declared as functions and may also be
defined as macros:
void *shmat(int shmid, const void *shmaddr, int shmflg);
int shmctl(int shmid, int cmd, struct shmidds *buf);
int shmdt(const void *shmaddr);
int shmget(keyt key, sizet size, int shmflg);
Page 1 Reliant UNIX 5.44 Printed 11/98
shm(5) shm(5)
In addition, all of the symbols from <sys/ipc.h> will be defined when
this header is included.
SEE ALSO
shmat(2), shmctl(2), shmdt(2), shmget(2), types(5).
Page 2 Reliant UNIX 5.44 Printed 11/98