Guardian Procedure Calls Reference Manual
If 1, requests allocation of a โshared segmentโ that is shared by the filename method. A shared
segment is an extended data segment that can be shared with other processes in the same processor.
<3>
The file-name parameter must be supplied when this type of shared segment is allocated. (It is
with the pin-and-flags parameter that sharing is specified.) Processes sharing a segment through
the file-name method can reference the address space by different segment-ids and may supply
different values of segment-size to ALLOCATESEGMENT. The segment-size supplied by the
first allocator of a particular shared segment (as identified by the swap file name) will limit the size
of the segment for subsequent processes attempting to share that segment. All processes that share
segments with the file-name method must have bit 3 and bit 1 set to 1. See Examples (page 62).
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
<2>
can be 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.
If 1, bits <8:15> are ignored.<1>
If 0, designates that segment sharing is to be done by the PIN method. The process calling
ALLOCATESEGMENT with bit 1 set to 1 shares the segment specified with the currently running
process specified by the PIN in bits <8:15> of the pin-and-flags word. The segment specified
by segment-id must have been previously allocated by the process specified in the
pin-and-flags word. Processes sharing a segment by this method reference the segment by the
same segment-id.
Examples of valid pin-and-flags word values are:
Allocate a shared segment, to be shared using the PIN method with the process identified by the
PIN specified in nnn.
%000nnn
Standard call to allocate a segment (default values).%040000
Allocate a segment to be shared by the file-name method.%050000
Allocate an extensible segment.%044000
Allocate an extensible segment to be shared by the file-name method.%054000
Allocate a read-only segment.%060000
Returned Value
INT
A status value that indicates the outcome of the call:
No error.0
File-system error related to the creation or open of the swap file (see file-name parameter).1-999
Invalid segment-id.-1
Invalid segment-size.-2
Bounds violation on file-name.-3
Invalid combination of options.-4
Unable to allocate segment space.-5
Unable to allocate segment page table space.-6
Security violation on attempt to share segment.-7
The pin parameter does not exist.-8
The pin parameter does not have the segment allocated.-9
Trying to share segment with self.-10
Requested segment is currently being resized (delay and try again), or the requested segment is a shared
selectable segment but the allocated segment is a flat segment.
-11
ALLOCATESEGMENT Procedure (Superseded by SEGMENT_ALLOCATE[64]_ Procedures) 61