Guardian Application Conversion Guide

Creating and Managing a High-PIN Process
Converting TAL Applications
096047 Tandem Computers Incorporated 3–21
Using the Process Name
From PROCESS_CREATE_
After calling PROCESS_CREATE_ , you might want to save the process name (if one
exists) from either the
process^desc
output parameter or system message -102 for
later use in your program. Save this name immediately after you receive it, because:
If you don’t save the name and you need the name later, you must convert the
process handle to a process name using the PROCESSHANDLE_TO_FILENAME_
procedure. If the process is running on a remote system, using
PROCESSHANDLE_TO_FILENAME_ implicitly sends a message to the remote
system. Your program must wait until the operation finishes.
If the process handle represents a named process (or process pair), you cannot
determine the process name from the process handle after the named process (or
process pair) has terminated.
Using the Process Handle
and Process Descriptor
From PROCESS_CREATE_
After calling the NEWPROCESS[NOWAIT] procedure, your existing program might
use the four-word
process^id
output parameter directly in a file-system procedure
such as an OPEN call. For example:
CALL NEWPROCESS (filenames,
priority,
memory^pages,
processor,
process^id,
error,
process^name);
...
CALL OPEN (process^id,
file^number);
Instead of a four-word process ID, PROCESS_CREATE_ returns these parameters for
the new process:
A process handle, which you can use with process-control procedures such as
PROCESS_STOP_ and PROCESS_ACTIVATE_ and with status-monitoring
procedures such as OPENER_LOST_ and CHILD_LOST_.
A process descriptor, which always includes the node name and a system-
assigned sequence number. The
process^desc^length
parameter contains the
length in bytes of the process descriptor.