Guardian Application Conversion Guide

Creating and Managing a High-PIN Process
Converting TAL Applications
096047 Tandem Computers Incorporated 3–19
User-Specified Name
Alternatively, you can specify a name for the new process when calling
PROCESS_CREATE_ by following these steps:
1. Set the
name^option
parameter to the LITERAL
ZSYS^VAL^PCREATEOPT^NAMEINCALL.
2. Set the
name
parameter to the process name. This name must be a variable-length
file-name string.
3. Set the
name^length
parameter to the length in bytes of the process name.
4. Set any other PROCESS_CREATE_ parameters as needed and call the procedure.
If the operation is successful, the system creates the process with the name you
specified in Step 2.
5. Check the results as described in Step 4 under “System-Generated Name,” earlier
in this section.
In this example, PROCESS_CREATE_ creates a high-PIN process in a waited manner.
The user supplies the name and name length:
name^option := ZSYS^VAL^PCREATEOPT^NAMEINCALL;
proc^name ':=' "$MYPROC.#first" -> @S^PTR;
proc^name^length := @S^PTR '-' @proc^name;
max^length := ZSYS^VAL^LEN^PROCESSDESCR;
error := PROCESS_CREATE_(program^file:pf^length,
! library^file:lf^length ! ,
! swapfile:sf^length ! ,
! ext^swapfile:esf^length ! ,
priority,
cpu^number,
process^handle,
error^detail,
name^option,
proc^name:proc^name^length,
process^desc:max^length,
process^desc^length);
Note If the RUNNAMED object-file attribute is set for the program file, the D-series operating system generates
a name even if the PROCESS_CREATE_ name^option parameter is zero or omitted.