User`s guide

MACRO Compiler Directives
.JSB32_ENTRY
The scratch argument also pertains to the compilers temporary register usage.
On OpenVMS Alpha sytems, the compiler may use registers R13 and above as
temporary registers if they are unused in the routine source code. Because R13
through R15 must be preserved, if modified, on Alpha systems, the compiler
preserves those registers if it uses them.
However, if they appear in the scratch register set declaration, the compiler
will not preserve them if it uses them as temporary registers. As a result, these
registers may be scratched at routine exit, even if they were not used in the
routine source but are in the scratch set.
On OpenVMS I64 systems, the compiler will not use these registers as temporary
registers.
Because R2 through R12 are not preserved by default, their inclusion in the
scratch is for documentation purposes only.
preserve=<>
Register set that indicates those registers that should be preserved over the
routine call. This should include only those registers that are modified and whose
full 64-bit contents should be saved and restored.
This register set causes registers to be preserved by the compiler. By default, no
registers are preserved by the .JSB32_ENTRY directive.
This register set overrides the output and scratch register sets. If you specify a
register both in the preserve register set and in the output or scratch register
sets, the compiler will report the warning:
%AMAC-W-REGDECCON, register declaration conflict in routine A
Description
The .JSB32_ENTRY directive is an alternative way of declaring a JSB entry
point. It is designed to streamline the declaration of VAX MACRO routines that
operate within a well-defined, bounded application environment, such as that
of a single application or a self-contained subsystem. For any routine declared
with the .JSB32_ENTRY directive, the compiler does not automatically save or
restore any VAX registers (R2 through R12), therefore leaving the current 32-bit
operation untouched. When you use the .JSB32_ENTRY directive to declare a
JSB entry point, you are responsible for declaring and saving registers which
must be preserved.
If the externally visible entry points of a subsystem can be called from the 64-bit
environment, those entry points should not be declared with .JSB32_ENTRY.
Instead, .JSB_ENTRY (or .CALL_ENTRY) should be used so that the full 64-bit
register values are saved, if necessary.
Specialized Directives B–15