GDSX (Extended General Device Support) Manual

Service Routines
Extended General Device Support (GDSX) Manual529931-001
8-53
^PROCESS_CREATE_
BEGIN
DISKNAME ':=' ["$XYZ SOME FILE "];
CALL ^OPEN(DISKNAME, DISKFILE, ...);
IF < THEN
BEGIN
.
produce suitable error message
.
CALL ^TERMINATE;!Stop GDSX process
END;
END;
END;
^PROCESS_CREATE_
This procedure creates a new process in a waited or nowait manner, and, optionally,
assigns a symbolic process name to it. Having users call the TSCODE-supported
^PROCESS_CREATE_ procedure rather than the Guardian PROCESS_CREATE_
allows GDSX to maintain a table (PCBTBL) of processes for which it is the creator. By
means of this table, stop or abend system messages received by TSCODE can be
routed to the task that created the process being stopped.
If USCODE is unconverted, the USCODE tasks cannot call this procedure.
Unconverted USCODE must instead call ^NEWPROCESS, the equivalent C-series
service routine. If a task within an unconverted application calls this procedure, file-
system error 29 or 560 is returned.
Except for the following considerations, the syntax, condition code settings, and
considerations regarding this procedure are the same as the PROCESS_CREATE_
procedure in the Guardian Procedure Calls Reference Manual.
Considerations
Calling ^PROCESS_CREATE_ in a nowaited mode causes the calling task to be
suspended. Nowaited calls are supported only when creating processes on the
same node.
Because the working stack images of tasks are swapped to and from an extended
data segment during I/O operations, I/O must be performed to and from global
buffers.
If you want USCODE to provide calls to ^AWAITIO[X] in order to wait for I/O
completion on ^DEVICEINFO2, ^FILE_GETINFOBYNAME_, and
^PROCESS_CREATE_ service routines, as would be done for typical nowaited
Guardian procedure calls, you must set the PROCNOWAIT configuration
parameter to 1.
If you want TSCODE to supply AWAITIO[X] calls to complete these nowaited I/Os
on behalf of USCODE, you must set PROCNOWAIT to 0. See PROCNOWAIT on
page 2-70 for more information.