HP 3000 Manuals

ARG_RELOCATION [ HP Pascal/iX Reference Manual ] MPE/iX 5.0 Documentation


HP Pascal/iX Reference Manual

ARG_RELOCATION 

ARG_RELOCATION is an HP Pascal Option.

The ARG_RELOCATION option can be used to suppress parameter relocation
information for all procedure or function definitions and calls.  This
option is only useful for REAL and LONGREAL data types.

Syntax 

$ARG_RELOCATION {ON }$
                {OFF}
Parameters 

ON            Relocation information is generated for parameters and
              function returns.  For dynamic calls (FCALL, CALL and calls
              to procedural and functional parameters), REAL and LONGREAL
              parameters and function results are put into or assumed to
              be in general registers.

OFF           Relocation information is suppressed.  Additionally, for
              dynamic calls, REAL and LONGREAL parameters and function
              returns are put into or assumed to be in floating point
              registers.

Default       ON

Location      At front.

Parameter relocation information is used by the linker to make sure the
arguments and the function return are in the correct register type.
(General versus floating point.)

ARG_RELOCATION OFF might be useful for performance if the called
procedure is in a shared library (HP-UX) or executable library (MPE/iX),
or if dynamic calls are used with REAL or LONGREAL parameters or function
returns.

When ARG_RELOCATION ON is used, linker-supplied stubs copy floating point
registers to general registers and then back again in the library.  The
same thing is done for the function return.

When ARG_RELOCATION OFF is used, the linker assumes that everything is in
the correct register and generates no extra stubs.  For a dynamic call,
the compiler puts floating point parameters in floating point registers.

See Procedure Calling Conventions Reference Manual for more details on
parameter relocation stubs.

Example 

     $ARG_RELOCATION OFF$
     program args;
     procedure p_r(x : real); external;
     begin
       p_r(1.5);
     end.


CAUTION If the ARG_RELOCATION is used improperly, unexpected results may occur. Refer to the Procedure Calling Conventions Reference Manual for detailed information on how to use this option.


MPE/iX 5.0 Documentation