TACL Reference Manual

Statements and Programs
HP NonStop TACL Reference Manual429513-018
5-18
Creating Program Files
If a process fails to start, TACL sets MESSAGECODE to 0, COMPLETIONCODE to 4, and
TERMINATIONINFO to an error code that describes the failure. For more information,
see the #NEWPROCESS Built-In Function on page 9-266.
If you start a process successfully, TACL sets MESSAGECODE to 0, COMPLETIONCODE
to 0, and TERMINATIONINFO to 0.
When TACL receives a STOP or ABEND message from a D-series process, TACL
stores the termination information in the :_COMPLETION variable:
TACL tries to convert a PROCDEATH system message to a C-series STOP or ABEND
system message. Note, however, that if the message represents an unnamed high
PIN process, the message will not fit in :_COMPLETION. In this case, TACL fills
:_COMPLETION with zeros for numeric items and spaces for text items.
The PIN in the process identifier field is set to 255 for any high PIN value.
TACL stores the name of the terminating process in :_COMPLETION:PROCESS and
stores the name of the process that requested the termination in
:_COMPLETION:EXTERNAL:PROCESS. If, however, the requesting process has
stopped or is not named, TACL cannot access its name. In this case, TACL sets
:_COMPLETION:EXTERNAL:PROCESS to spaces. You can use CPU and PIN
information instead of the process name.
For more information about MESSAGECODE and other definitions and for an example of
TACL statements that process completion codes, see the TACL Programming Guide.
D-Series :_COMPLETION^PROCDEATH Variable
A D-series PIN does not fit into a CRTPID field, so D-series TACL stores D-series
completion information in the :_COMPLETION^PROCDEATH variable, if it exists. D-
series TACL receives PROCDEATH (-101) messages instead of STOP and ABEND
messages, and saves any PROCDEATH messages in the :_COMPLETION^PROCDEATH
variable, if it exists.
New D-series TACL applications should use the :_COMPLETION^PROCDEATH for
completion information.
If a requesting process is named and started on another processor and if that
processor fails, TACL still receives the PROCDEATH system message to fill in the
completion information. If the requesting process is unnamed, however, TACL does
not receive the PROCDEATH system message and the completion information is not
updated. The requesting process should be named to make sure the completion
information is updated. For more information on these limitations, see the Guardian
Procedure Calls Reference Manual.
The TACL software file, TACLSEGF, defines :_COMPLETION^PROCDEATH as follows:
[#DEF :_completion^procdeath STRUCT
BEGIN
INT z^msgnumber;
STRUCT z^base