Guardian Procedure Calls Reference Manual
ALLOCATESEGMENT Procedure (Superseded by
SEGMENT_ALLOCATE[64]_ Procedures)
Summary
Syntax for C Programmers
Syntax for TAL Programmers
Parameters
Returned Value
Considerations
Examples
Summary
NOTE: This procedure is supported for compatibility with previous software and should not be
used for new development.
The ALLOCATESEGMENT procedure allocates a selectable extended data segment for use by the
calling process. This procedure can create read/write segments or read-only segments.
The ALLOCATESEGMENT procedure can also be used to share selectable extended data segments
or flat extended data segments allocated by other processes (subject to the normal security
requirements). Although it is possible to share flat segments using the ALLOCATESEGMENT
procedure, flat segments can be allocated only by using the SEGMENT_ALLOCATE_ procedure.
SEGMENT_ALLOCATE_ can also allocate selectable segments.
For selectable extended data segments, the call to ALLOCATESEGMENT must be followed by a
call to USESEGMENT to make the segment accessible. Although you can allocate multiple selectable
extended data segments, you can access only one at a time.
For shared flat segments, the call to ALLOCATESEGMENT can be followed by a call to
USESEGMENT, but calling USESEGMENT is unnecessary because all the flat segments allocated
by a process are always accessible to the process.
Flat segments and selectable segments are supported on native processors that use D30 or later
RVUs. Selectable segments are supported on all systems.
Syntax for C Programmers
This procedure does not have a C syntax, because it is superseded and should not be used for
new development. This procedure is supported only for compatibility with previous software.
Syntax for TAL Programmers
status := ALLOCATESEGMENT ( segment-id ! i
,[ segment-size ] ! i
,[ file-name ] ! i,o
,[ pin-and-flags ] ); ! i
58 Guardian Procedure Calls (A-B)