Guardian Programmer's Guide

Table Of Contents
Introduction to Guardian Programming
Guardian Programmer’s Guide 421922-014
1 - 23
TNS/R Program Execution Modes
TNS/E native and TNS/R native object files differ in other respects as well. See the eld
Manual and the enoft Manual for details on the structure of TNS/E native object files.
TNS/R Program Execution Modes
TNS/R systems can execute TNS/R native code, TNS code, and accelerated code.
User processes can run in all three of these modes.
TNS/R native code is produced by a native compiler and consists entirely of RISC
instructions that have been arranged to take full advantage of the RISC architecture. A
program consisting of native code is called a native program. You can produce native
object code by using a native compiler. Refer to the C/C++ Programmer’s Guide and
the pTAL Programmer’s Guide for information about native compilers.
TNS code executes TNS instructions facilitated by millicode. Millicode is assembled
program code, consisting of RISC instructions, that implements various TNS low-level
functions. A program consisting of TNS code is called a TNS program. You produce
TNS object code by using a compiler that is not native. Actual TNS CPUs do not
support D40 or later versions of the operating system.
Accelerated code is produced by the Accelerator, a program that processes a TNS
object file to run more efficiently on a TNS/R CPU. An accelerated object file consists
of Accelerator-generated RISC instructions as well as the original TNS instructions. A
program that contains accelerated code is called an accelerated program. For more
information on using the Accelerator, see the Accelerator Manual.
The accelerated version of an object file almost always runs faster than the TNS
version; the native version of an object file almost always runs faster than the
accelerated version. The actual differences in execution speed between TNS,
accelerated, and native versions of the same program may vary, depending on the
constructs that are used in the source code.
A TNS/R native process is a process that is initiated by executing a TNS/R native
program. A native process executes in the native operating environment of the TNS/R
CPU.
A TNS process is a process that is initiated by executing a TNS or accelerated
program. A TNS process executes in an emulated TNS operating environment.
Using Parameter Declarations Files
HP provides a set of files that contain useful literals and data structures. Many of
these literals and data structures can be used in defining parameters for Guardian
procedure calls. The Data Definition Language (DDL) makes these literals available
from the TAL, C, COBOL85, and Pascal programming languages.
The following files are provided in the subvolume $SYSTEM.ZSYSDEFS:
ZSYSDDL contains the DDL declarations used to generate the other ZSYS files.