Guardian Procedure Calls Reference Manual
back out to the file. CHECKALLOCATESEGMENT must be able to allocate a sufficient number
of file extents to contain all memory in the segment.
The parameter can be a volume name with a blank subvolume and file;
CHECKALLOCATESEGMENT allocates a temporary swap file on the indicated volume.
If you do not specify file-name (and if a segment is not being shared using the PIN method),
CHECKALLOCATESEGMENT uses the volume of the data stack swap file to create a temporary
swap file for the new segment.
pin-and-flags
input
INT:value
Defaults to %040000. Its values are:
Optional PIN for segment sharing. Requests allocation of a shared segment that is shared by the PIN
method. This value specifies the process identification number (PIN) of the process that has previously
<8:15>
allocated the segment and with which the caller wants to share the segment. This value is not used if bit
1 is set to 1 (see bit 1 later).
Not used; must be zero (0).<5:7>
If 1, requests allocation of an extensible segment. An extensible segment is an extended data segment
for which the underlying swap file disk space is not allocated until needed. In this case, the value of
<4>
segment-size allocated by the primary process is taken as a maximum size, and the underlying virtual
memory is expanded dynamically as the user accesses various addresses within the extended data
segment. When the user first accesses a portion of an extensible data segment for which the corresponding
swap file extent hasn’t been allocated, the operating system allocates the extent. If this extent cannot
be allocated, the user process terminates: a TNS Guardian process terminates with a “no memory
available” trap (trap 12); an OSS or native process receives a SIGNOMEM signal.
If 1, requests allocation of a “shared segment.” A shared segment is an extended data segment that
can be shared with other processes in the processor. The file-name parameter must be supplied when
<3>
a shared segment is allocated. Processes sharing segments by this mechanism can reference the address
space by different segment IDs and can supply different values of segment-size to
ALLOCATESEGMENT. The value of segment-size supplied by the very first allocator of a particular
shared segment (as identified by the swap file name) limits the size of the segment for subsequent
processes attempting to share that segment.
If 1, requests allocation of a read-only segment. A read-only segment is an extended data segment that
is initialized from a preexisting swap file and used only for read access. A read-only segment can be
<2>
shared by either the PIN or file-name method. It can also be shared by file-name between processes
in different processors. Note that the file-name parameter must specify the name of an existing swap
file that is not empty. If this bit is 1, bit <4> of pin-and-flags must be 0 (writeback-inhibit extensible
segments are not allowed) and bit 1 must be set to 1, indicating a shared segment.
If 1, bits <8:15> are ignored. If 0, designates that the extended data segment specified by segment-id
is to be shared with the process specified by the PIN in bits <8:15> of pin-and-flags. For this
sharing to occur, the processes must execute in the same processor and one of these must be true:
<1>
• The processes share the same process access ID (PAID).
• This process’s PAID must be the group manager for the PAID of the other process.
• This process’s PAID must be the super ID (255,255).
Processes sharing a segment by the PIN method reference the segment by the same value of segment-id.
error
output
INT .EXT:ref:1
indicates the outcome of the call. This procedure returns all values returned by
ALLOCATESEGMENT in the backup, plus these file-system errors:
Segment is not allocated by the primary, or segment ID is invalid.2
Bounds error on file name.22
CHECKALLOCATESEGMENT Procedure (Superseded by SEGMENT_ALLOCATE_CHKPT_ Procedure) 129