This standard also defines properties of the run-time environment that must apply at various points during program execution. These properties vary in scope and applicability. Some properties apply to all points throughout the execution of standard-conforming user-mode code and must, therefore, be held constant at all times. Such properties include those defined for the stack pointer and various properties of the call-chain navigation mechanism. Other properties apply only at certain points; for example, call conventions that apply only at the point of transfer of control to another procedure.
Furthermore, some properties are optional, depending on circumstances.
For example, compilers
are not obligated to follow the argument list conventions
when a procedure and all of its callers are in the same module, have been
analyzed by an interprocedural analyzer, or have private interfaces such as
language-support routines.
In many cases, significant performance gains can be realized by selective
use of nonstandard calls when the safety of such calls is known. Compiler
writers are encouraged to make full use of such optimizations, but should
make sure that procedures outside the compilation unit can proceed as if the
standard were met.
This standard applies to the following:
The interfaces, methods, and conventions specified in this document
are primarily intended for use by implementors of compilers, debuggers, other
run-time tools, run-time libraries, and other base operating system components.
These specifications can be, but are not necessarily, appropriate for use
by higher-level system and software applications.
Compilers and run-time libraries may provide additional support for
these capabilities through interfaces that are more appropriate for compilers
and applications. This standard neither prohibits nor requires such additional
interfaces.
The calling standard must be applicable to all intermodule callable
interfaces in the native software system. The standard must consider the
requirements of important compiled languages, including Ada, BASIC, C, C++,
COBOL, FORTRAN, LISP, Pascal, PL/I, and calls to the operating system and
library procedures. The needs of other languages that may be supported in
the future must be met by the standard or by compatible revisions to it.
The goals of the Digital UNIX calling standard are to:
This calling standard is designed to allow a compiler to determine whether
to use a stack frame based on the complexity of the procedure being compiled.
A recompilation of a called routine that causes a change in stack frame usage
should not require a recompilation of its callers.
While the normal control flow is interrupted by an exception, the program
flow is said to be in the active
state.
This standard applies to the execution of multiple threads within a
process. (An operating system that only provides a single thread of execution
per process is considered a special case of a multithreaded system; that is,
one where the maximum number of threads per process is 1.)
Therefore, all results caused by operations defined in the Digital UNIX
implementation of the calling standard, but not specified as part of the calling
standard are considered unpredictable. Standard-conforming procedures cannot
depend on unpredictable results.
Note
The conventions specified in this standard are intended to exploit fully
the architectural and performance advantages of the Alpha hardware.
Some of these conventions are visible to the high-level
language programmer and, therefore, might require source changes in high-level
language programs when they are ported from other environments. Users should
not depend on the properties of the Alpha architecture to achieve source-level
compatibility and portability between Digital UNIX for Alpha systems and other
UNIX environments, except indirectly through high-level language facilities
that are portable across architectures.
1.1 Applicability
This manual defines the rules and conventions that govern the native user-mode run-time environment
on Digital UNIX systems running on Alpha
hardware. The standard is applicable to all products in native user mode
on the Digital UNIX operating system.
1.2 Architectural Level
This Digital UNIX calling standard defines an implementation-level
run-time software architecture for Digital UNIX operating systems
running on Alpha hardware.
1.3 Goals
In general, this Digital UNIX calling standard promotes the highest
degree of performance, portability, efficiency, and consistency in the interface
between called procedures in the Digital UNIX environment.
1.4 Requirements
The Digital UNIX calling standard was developed with the following requirements:
1.5 Definitions
The following terms are used in the Digital UNIX calling standard: