HP Fortran for OpenVMS
User Manual


Previous Contents Index

2.3.8 /AUTOMATIC --- Data Storage

The /AUTOMATIC and /NOAUTOMATIC qualifiers are synonyms of /RECURSIVE or /NORECURSIVE (see Section 2.3.38). This qualifier is provided for Compaq Fortran 77 compatibility.

2.3.9 /BY_REF_CALL --- Character Literal Argument Passing

Specifying /BY_REF_CALL=routine-list indicates that character constants used as actual arguments in calls to the specified routines be passed by reference and not by character descriptor. This helps applications that pass quoted character constants to numeric dummy parameters, such as applications ported from OpenVMS VAX systems that rely on the OpenVMS VAX Linker to change the argument passing mechanism for character constant actual arguments.

By default, HP Fortran passes character constants used as actual arguments by the usual OpenVMS character descriptor mechanism.

You can specify a list of routines or use wildcard characters (such as an asterisk (*)) to indicate all routines, for example:


$ FORTRAN/BY_REF_CALL=(PROJA_ROUT,PROJB_ROUT) TEST.FOR
$ FORTRAN/BY_REF_CALL=(*) APPLIC.FOR

The first FORTRAN command requests special character constant actual argument handling for two specific routines. The second requests this for all routines. You can select routines whose names match certain characters and a wildcard, such as all routines that start with MY:


$ FORTRAN/BY_REF_CALL=(MY*) X.FOR

2.3.10 /CCDEFAULT --- Carriage Control for Terminals

The /CCDEFAULT qualifiers specify default carriage control when a terminal or printer displays a file.

The qualifier has the following form:

/CCDEFAULT=
    • FORTRAN
    • LIST
    • NONE
    • DEFAULT

FORTRAN

Specifying /CCDEFAULT=FORTRAN results in normal Fortran interpretation of the first character, such as the character "0" resulting in a blank line before output.

LIST

Specifying /CCDEFAULT=LIST results in one linefeed between records.

NONE

Specifying /CCDEFAULT=NONE results in no carriage control processing.

DEFAULT

Specifying /CCDEFAULT=DEFAULT results in the possibility of other qualifiers, such as /VMS, affecting this default setting: if /NOVMS is specified, the default is LIST; otherwise, the default is FORTRAN.

2.3.11 /CHECK --- Generate Code for Run-Time Checking

The /CHECK qualifier requests certain error checking during program execution (run time). The compiler produces extra code that performs the checks.

The qualifier has the following form:

/CHECK=
    • [NO]ARG_INFO (I64 only)
    • [NO]ARG_TEMP_CREATED
    • [NO]BOUNDS
    • [NO]FORMAT
    • [NO]FP_EXCEPTIONS
    • [NO]FP_MODE (I64 only)
    • [NO]OUTPUT_CONVERSION
    • [NO]OVERFLOW
    • [NO]POWER
    • [NO]UNDERFLOW
    [, ...]
    • ALL
    • NONE

[NO]ARG_INFO (I64 only)

Controls whether run-time checking of the actual argument list occurs. For actual arguments that correspond to declared formal parameters, the check compares the run-time argument type information for arguments passed in registers with the type that is expected. An informational message is issued at run time for each miscompare. Extra actual arguments or too few actual arguments are not reported.

With the default, NOARG_INFO, no check is made.

ARG_TEMP_CREATED

Controls whether a run-time warning message is displayed (execution continues) if a temporary is created for an array actual argument passed to a called routine.

[NO]BOUNDS

Controls whether run-time checking occurs for each dimension of an array reference or substring reference to determine whether it is within the range of the dimension specified by the array or character variable declaration.

Specify BOUNDS to request array bounds and substring checking. With the default, NOBOUNDS, array bounds and substring checking does not occur.

[NO]FORMAT

Controls whether the run-time message number 61 (FORVARMIS) is displayed and halts program execution when the data type for an item being formatted for output does not match the format descriptor being used (such as a REAL data item with an I format).

The default, FORMAT, causes FORVARMIS to be a fatal error and halts program execution.

Specifying NOFORMAT ignores the format mismatch, which suppresses the FORVARMIS error and allows program continuation.

If you omit /NOVMS and omit /CHECK=NOFORMAT, the default is /CHECK=FORMAT.

If you specify /NOVMS, the default is NOFORMAT (unless you also specify /CHECK=FORMAT).

[NO]FP_EXCEPTIONS

Controls whether run-time checking counts calculations that result in exceptional values. With the default, NOFP_EXCEPTIONS, no run-time messages are reported.

Specifying FP_EXCEPTIONS requests reporting of the first two occurrences of each type of exceptional value and a summary run-time message at program completion that displays the number of times exceptional values occurred. Consider using FP_EXCEPTIONS when the /IEEE_MODE qualifier allows generation of exceptional values.

To limit reporting to only denormalized numbers (and not other exceptional numbers), specify UNDERFLOW instead of FP_EXCEPTIONS.

Using FP_EXCEPTIONS applies to all types of native floating-point data.

[NO]FP_MODE (I64 only)

Controls whether run-time checking of the current state of the processor's floating-point status register (FPSR) occurs. For every call of every function or subroutine, the check will compare the current state of the FPSR register against the expected state. That state is based on the /FLOAT, /IEEE_MODE and /ROUND qualifier values specified by the FORTRAN command. An informational message is issued at run time for miscompares.

With the default, NOFP_MODE, no check is made.

[NO]OUTPUT_CONVERSION

Controls whether run-time message number 63 (OUTCONERR) is displayed when format truncation occurs. Specifying /CHECK=NOOUTPUT_CONVERSION disables the run-time message (number 63) associated with format truncation. The data item is printed with asterisks. When OUTPUT_CONVERSION is in effect and a number could not be output in the specified format field length without loss of significant digits (format truncation), the OUTCONERR (number 63) error occurs.

If you omit /NOVMS and omit /CHECK=NOOUTPUT_CONVERSION, the default is OUTPUT_CONVERSION.

If you specify /NOVMS, the default is NOOUTPUT_CONVERSION (unless you also specify /CHECK=OUTPUT_CONVERSION).

[NO]OVERFLOW

Controls whether run-time checking occurs for arithmetic overflow of all integer calculations (INTEGER, INTEGER with a kind parameter, or INTEGER with a length specifier). Specify OVERFLOW to request integer overflow checking.

Real and complex calculations are always checked for overflow and are not affected by /NOCHECK. Integer exponentiation is performed by a routine in the mathematical library. The routine in the mathematical library always checks for overflow, even if NOOVERFLOW is specified.

With the default, NOOVERFLOW, overflow checking does not occur.

[NO]POWER

Specifying the /CHECK=NOPOWER qualifier allows certain arithmetic expressions containing floating-point numbers and exponentiation to be evaluated and return a result rather than cause the compiler to display a run-time message and stop the program. The specific arithmetic expressions include:

For example, if you specify /CHECK=NOPOWER the calculation of the expression 0.0 ** 0.0 results in 1. The expression (--3.0) ** 3.0 results in --27.0.

If you omit /CHECK=NOPOWER for such expressions, an exception occurs, error message number 65 is displayed, and the program stops (default is /CHECK=POWER).

[NO]UNDERFLOW

Controls whether run-time messages are displayed for floating underflow (denormalized numbers) in floating-point calculations. Specifying UNDERFLOW might be used in combination with the /IEEE_MODE=DENORM_RESULTS qualifier. Specify UNDERFLOW to request reporting of the first two occurrences of denormalized numbers and a summary run-time message at program completion that displays the number of times denormalized numbers occurred.

The default, NOUNDERFLOW, means that floating underflow messages are not displayed. To check for all exceptional values (not just denormalized numbers), specify /CHECK=FP_EXCEPTIONS.

ALL

Requests that all run-time checks (BOUNDS, FORMAT, FP_EXCEPTIONS, OUTPUT_CON2VERSION, OVERFLOW, and UNDERFLOW) be performed. Specifying /CHECK and /CHECK=ALL are equivalent.

NONE

Requests no run-time checking. This is the default. Specifying /NOCHECK and /CHECK=NONE are equivalent.

For More Information:

2.3.12 /CONVERT --- Unformatted Numeric Data Conversion

The /CONVERT qualifier specifies the format of numeric unformatted data in a file, such as IEEE little endian, VAX G_float, VAX D_float floating-point format, or a nonnative big endian format.

By default, an unformatted file containing numeric data is expected to be in the same floating-point format used for memory representation or /CONVERT=NATIVE. You set the floating-point format used for memory representation using the /FLOAT qualifier (see Section 2.3.22).

Instead of specifying the unformatted file format by using the /CONVERT qualifier, you can use one of the other methods (predefined logical names or the OPEN CONVERT keyword) described in Chapter 9, which allow the same program to use different floating-point formats, as shown in Figure 2-1.

The qualifier has the following form (specify one keyword):

/CONVERT=
  • BIG_ENDIAN
  • CRAY
  • FDX
  • FGX
  • IBM
  • LITTLE_ENDIAN
  • NATIVE
  • VAXD
  • VAXG

BIG_ENDIAN

Specifies that unformatted files containing numeric data are in IEEE big endian (nonnative) format.

If you specify BIG_ENDIAN, the resulting program will read and write unformatted files containing numeric data assuming:

CRAY

Specifies that unformatted files containing numeric data are in CRAY (nonnative) big endian format.

If you specify CRAY, the resulting program will read and write unformatted files containing numeric data assuming:

FDX

Specifies that unformatted files containing numeric data are in I64/Alpha-compatible D_float-centered little endian format, as follows:

FGX

Specifies that unformatted files containing numeric data are in I64/Alpha-compatible G_float-centered little endian format, as follows:

IBM

Specifies that unformatted files containing numeric data are in IBM® (nonnative) big endian format (such as IBM System\370 and similar systems).

If you specify IBM, the resulting program will read and write unformatted files containing numeric data assuming:

LITTLE_ENDIAN

Specifies that unformatted files containing numeric data are in native little endian integer format and IEEE little endian floating-point format, as follows:

NATIVE

Specifies that the format for unformatted files containing numeric data is not converted. When using NATIVE (the default), the numeric format in the unformatted files must match the floating-point format representation in memory, which is specified using the /FLOAT qualifier.

This is the default.

VAXD

Specifies that unformatted files containing numeric data are in VAX-compatible D_float-centered little endian format, as follows:

VAXG

Specifies that unformatted files containing numeric data are in VAX-compatible G_float-centered little endian format, as follows:

For More Information:

2.3.13 /D_LINES --- Debugging Statement Indicator, Column 1

Specify /D_LINES to request that the compiler should treat lines in fixed-form source files that contain a D in column 1 as source code rather than comment lines. Such lines might print the values of variables or otherwise provide useful debugging information. This qualifier is ignored for free-form source files.

The default is /NOD_LINES, which means that lines with a D in column 1 are treated as comments.

2.3.14 /DEBUG --- Object File Traceback and Symbol Table

The /DEBUG qualifier requests that the object module contain information for use by the OpenVMS Debugger and the run-time error traceback mechanism.

The qualifier has the following form:

/DEBUG=
    • [NO]SYMBOLS
    • [NO]TRACEBACK
    [, ...]
    • NONE
    • ALL

[NO]SYMBOLS

Controls whether the compiler provides the debugger with local symbol definitions for user-defined variables, arrays (including dimension information), structures, parameter constants, and labels of executable statements.

[NO]TRACEBACK

Controls whether the compiler provides an address correlation table so that the debugger and the run-time error traceback mechanism can translate virtual addresses into source program routine names and compiler-generated line numbers.

ALL

Requests that the compiler provide both local symbol definitions and an address correlation table. If you specify /DEBUG without any keywords, it is the same as /DEBUG=ALL or /DEBUG=(TRACEBACK,SYMBOLS). When you specify /DEBUG, also specify /NOOPTIMIZE to prevent optimizations that complicate debugging.

NONE

Requests that the compiler provide no debugging information. The /NODEBUG, /DEBUG=NONE, and /DEBUG=(NOTRACEBACK, NOSYMBOLS) qualifiers are equivalent.

If you omit /DEBUG, the default is /DEBUG=(TRACEBACK, NOSYMBOLS).

Note

The use of /NOOPTIMIZE is strongly recommended when the /DEBUG qualifier is used. Optimizations performed by the compiler can cause several different kinds of unexpected behavior when using the OpenVMS Debugger.

For More Information:

2.3.15 /DIAGNOSTICS --- Create Diagnostics File

The /DIAGNOSTICS qualifier creates a file containing compiler messages and diagnostic information.

The qualifier has the following form:

/DIAGNOSTICS[=file-spec]

The default is /NODIAGNOSTICS.

If you omit the file specification, the diagnostics file has the name of your source file and a file type of DIA.

The diagnostics file is reserved for use with third-party layered products such as, but not limited to, the Language Sensitive Editor (LSE).

For More Information:

On using LSE, see the Guide to Source Code Analyzer for VMS Systems or online LSE HELP.

2.3.16 /DML --- Invoke Fortran DML Preprocessor

The /DML qualifier invokes the Fortran Data Manipulation Language (DML) preprocessor before the compiler. The preprocessor produces an intermediate file of HP Fortran source code in which Fortran DML commands are expanded into HP Fortran statements. The compiler is then automatically invoked to compile this intermediate file.

The qualifier has the following form:

/DML

The default is not to invoke the Fortran DML preprocessor.

Use the /SHOW=PREPROCESSOR qualifier in conjunction with the /DML qualifier to cause the preprocessor-generated source code to be included in the listing file.

Any switches preceding the /DML qualifier in the command line are ignored.

Note

Unless you specify the /DEBUG qualifier, the intermediate file is deleted by the Fortran DML preprocessor immediately after compilation is complete, and the Language Sensitive Editor and the Source Code Analyzer cannot access the source program when you use the /DML qualifier. The results with the /DEBUG qualifier reflect the intermediate source.

For More Information:

On the DML preprocessor, see the Oracle CODASYL DBMS Programming Reference Manual.


Previous Next Contents Index