f90/f95/f77(1) f90/f95/f77(1)
Compaq Compaq
Name
f90 - invokes the Compaq Fortran 90 (formerly DIGITAL Fortran 90) compiler
f95 - invokes the Compaq Fortran 95 (formerly DIGITAL Fortran 95) compiler
f77 - invokes the Compaq Fortran 90 (formerly DIGITAL Fortran 90) compiler
f77 -old_f77 - invokes the Compaq Fortran 77 (formerly DIGITAL Fortran 77)
compiler
Syntax
f90 [ options ] filename [ options ]
f95 [ options ] filename [ options ]
f77 [ options ] filename [ options ]
Performance Enhancing Options
The following command line options can be used to increase the run-time
performance of code generated by the Compaq Fortran compiler:
-arch, -fast, -O, -tune.
Description
The f90, f95, and f77 commands invoke the specified Compaq Fortran com-
piler. They produce Compaq Tru64 UNIX (formerly DIGITAL UNIX) extended coff
object files; the f90 and f95 commands also produce Fortran 90 module
information files. These commands may also invoke the C compiler ( cc(1) )
or the C preprocessor ( cpp(1) ).
The f77 command now executes the Compaq Fortran 90 compiler by default. If
you want to use the Compaq Fortran 77 compiler, you must use the -old_f77
option with the f77 command.
The f90, f95, and f77 commands interpret arguments (filenames) as follows:
+ Arguments with the suffix .f90 or .F90 are assumed to be free-form
(Fortran 90 style) source files. Arguments with the suffix .f, .for,
or .FOR are assumed to be fixed-form (FORTRAN 77 style) source forms.
When the -c option is specified without the -o option, an object file
is created in the current directory; the file has the basename of the
source file with an .o suffix. (For example, in source file
myfile.f90, myfile is the basename; so the object program is named
myfile.o.) If the source program is compiled and loaded, the .o file
is deleted.
+ Arguments with the suffix .F are assumed to be Fortran fixed-form
source programs, which must be processed by the C preprocessor (
cpp(1) ) before being compiled. cpp(1) produces a file with the suf-
fix .i.
Note that if you have myfile.F and myfile.i as distinct files, cpp(1)
overwrites myfile.i to produce an output file with the same name.
+ Arguments with the suffix .F90 are assumed to be Fortran free-form
source programs, which must be processed by the C preprocessor (
cpp(1) ) before being compiled. cpp(1) produces a file with the
suffix .i90.
Note that if you have myfile.F90 and myfile.i90 as distinct files,
cpp(1) overwrites myfile.i90 to produce an output file with the same
name.
+ Arguments with the suffix .i are assumed to be fixed-form source pro-
grams that have been processed by the C preprocessor ( cpp(1) ). They
are compiled without further processing.
+ Arguments with the suffix .i90 are assumed to be free-form source pro-
grams that have been processed the C preprocessor ( cpp(1) ). They
are compiled without further processing.
If a Fortran 90 or 95 source file contains MODULE declarations, a file is
created with the basename of the module and the .mod suffix.
The following are environmental variables that can be set:
+ DECF90: The location of the f90 compiler to invoke.
+ DECFORT: The location of the f77 compiler to invoke.
+ DECF90_CC: The location of the cc command for the f90 compiler.
+ DECFORT_CC: The location of the cc command for the f77 compiler.
+ DECFORT_FPP: The name of the preprocessor for FORTRAN 77 files.
+ DECF90_INIT: Initial options for the f90 (or f95) command. If this
variable is defined, its value has to have the form:
[[pre] [:: [post]]
where the items in "[ ]" are optional and can be empty, and where
"pre" and "post" are strings to be added to the command line. "pre"
is added to the front of the command line, before any characters the
user typed; "post" is added to the end of the command line.
+ DECFORT_INIT: Initial options for the f77 command. If this variable
is defined, its value has to have the form shown previously for
DECF90_INIT.
+ TMPDIR: The directory for temporary files.
The f90, f95, and f77 commands pass the following command line options to
cpp(1): -Dname, -Dname=def, -I, -Idir, -M, -Uname, and options from
-Wp,....
The f90 command defines the following cpp(1) macros to cpp(1):
LANGUAGE_FORTRAN_90, __LANGUAGE_FORTRAN_90__, LANGUAGE_FORTRAN,
__LANGUAGE_FORTRAN__, unix, __unix__, __alpha, and __osf__.
The f95 command defines the following cpp(1) macros to cpp(1):
LANGUAGE_FORTRAN_95, __LANGUAGE_FORTRAN_95__, LANGUAGE_FORTRAN,
__LANGUAGE_FORTRAN__, unix, __unix__, __alpha, and __osf__.
The f90 and f95 commands define the following cpp(1) macro to cpp(1) if
option -omp is specified: _OPENMP.
The f77 command defines the following cpp(1) macros to cpp(1):
LANGUAGE_FORTRAN, __LANGUAGE_FORTRAN__, unix, __unix__, __alpha, and
__osf__.
The following examples demonstrate optimizing across multiple input files:
1. f90 ax.f90
This command compiles ax.f90 producing executable file a.out.
Optimizations occur by default.
2. f90 -o abc ax.f90 bx.f90 cx.f90
This command uses option -o to name the executable file abc
and compiles ax.f90, bx.f90, and cx.f90 as one program.
Interprocedural optimization occurs across ax, bx, and cx.
3. f90 -c ax.f90 bx.f90 cx.f90
This command uses option -c to suppress linking and produce
individual object files ax.o, bx.o, and cx.o. Inter-
procedural optimizations are prevented.
4. f90 -c -o abc.o ax.f90 bx.f90 cx.f90
This command uses option -c to suppress linking, and option
-o to produce a single object file abc.o. Interprocedural
optimization occurs.
5. f90 -o foo ax.f bx.f cx.f
This command causes the files ax.f, bx.f, and cx.f to be
compiled as one program, with the resulting executable
file foo. Interprocedural optimization occurs.
6. f90 -c -O4 ax.f bx.f cx.f
This command causes the files ax.o, bx.o and cx.o to
be created. Interprocedural optimization is hindered
because these input files are separately compiled.
7. f90 -c -o foo.o -O4 ax.f bx.f cx.f
This command causes the files ax.f, bx.f and cx.f to be
compiled as one program, with the resulting object file
foo.o. This produces better optimization.
f90, f95, and f77 send their output to stderr. Upon completion, the respec-
tive driver returns one of the following status values:
0 - SUCCESS
1 - FAILURE
2 - SUBPROCESS_FAILURE (preprocessor, compiler, or ld)
3 - SIGNAL
You can override some options specified on the command line by using the
OPTIONS statement in your Fortran source program. An OPTIONS statement
affects only the program unit where the statement occurs. For more infor-
mation, see your language reference manual.
For more information on the current version of the Compaq Fortran 90 com-
piler, see the release notes in /usr/lib/cmplrs/fort90/relnotes90 .
For more information on the current version of the Compaq Fortran 77 com-
piler, see the release notes in /usr/lib/cmplrs/fort/relnotes .
Options
Some options have the form -name keyword. The -name must be spelled out
completely, but the keyword can be abbreviated to its shortest unique pre-
fix (4 characters are recommended). For example, -check output_conversion
can be specified as -check outp.
The f90, f95, and f77 commands take the following options unless otherwise
noted (see ld(1) for linker and load-time options):
-1 Executes at least one iteration of DO loops. (FORTRAN 77 DO
loops are not executed if the upper limit is smaller than the
lower limit.) This option has the same effect as -nof77.
-66 Allows extensions that enhance FORTRAN-66 compatibility. This
option has the same effect as -nof77.
-align commons
Aligns all COMMON block entities on natural boundaries up to
4-bytes instead of the default byte boundary. The default is
-align nocommons.
-align dcommons
Aligns all COMMON block entities on natural boundaries up to
8-bytes instead of the default byte boundary. The default is
-align nocommons. For optimal performance on Alpha systems,
specify -align records (the default) and -align dcommons.
-align norecords
Aligns fields within record structures and components of
derived types ( f90 and f95 only ) on the next available byte
boundary instead of the default natural boundaries. The
default is -align records.
-align recNbyte
f90 and f95 only. Aligns fields of records and components of
derived types on the smaller of the size boundary specified (N
can be 1, 2, 4, or 8) or the boundary that will naturally align
them. Specifying -align recNbyte does not affect whether com-
mon blocks are naturally aligned or packed.
-align sequence
f90 and f95 only. Specifies that components of a SEQUENCEd
derived type are to be aligned according to the alignment rules
set by the user. The default alignment rules are to align com-
ponents on natural boundaries. The default is -align nose-
quence, which causes components of a SEQUENCEd derived type to
be packed, regardless of the current alignment rules set by the
user.
-arch Determines which version of the Alpha architecture the compiler
generates instructions for. The format is:
-arch generic | host | ev4 | ev5 | ev56 | ev6 | ev67 | pca56
All Alpha processors implement a core set of instructions, with
possible extensions. Some of the instruction set extensions
are:
BWX - Byte/Word manipulation instructions
MAX - Multimedia instructions
The Alpha Architecture reference manual describes these exten-
sions in detail.
The -arch option selected determines whether or not the com-
piler can generate instructions that are part of these exten-
sions.
The operating system kernel includes an instruction emulator
that allows new instructions, not implemented on the host pro-
cessor chip, to execute and produce correct results.
Applications using emulated instructions will run correctly,
but may incur significant emulation overhead at runtime.
The following are -arch options:
+ -arch generic
Generates instructions that are appropriate for most Alpha
processors. This is the default.
+ -arch host
Generates instructions for the machine the compiler is run-
ning on (for example, ev56 instructions on an ev56 proces-
sor and ev4 instructions on an ev4 processor).
+ -arch ev4
Generates instructions for ev4 processors (for 21064,
20164A, 21066, and 21068 chips).
Applications compiled with this option will not incur any
emulation overhead on any Alpha processor.
+ -arch ev5
Generates instructions for ev5 processors (some 21164
chips).
Applications compiled with this option will not incur any
emulation overhead on any Alpha processor.
+ -arch ev56
Generates instructions for ev56 processors (some 21164
chips).
This option permits the compiler to generate any ev4
instruction plus any instruction contained in the BWX
extension.
Applications compiled with this option may incur emulation
overhead on ev4 and ev5 processors, but will still run
correctly.
+ -arch ev6
Generates instructions for ev6 processors (21264 chips).
This option permits the compiler to generate any ev6
instruction, including instructions contained in the BWX or
MAX extension, and square root and floating-point convert
extension (FIX).
Applications compiled with this option may incur emulation
overhead on ev4, ev5, ev56, and pca56 processors, but will
still run correctly.
+ -arch ev67
Generates instructions for ev67 processors (21264A chips).
This option permits the compiler to generate any ev67
instruction, including instructions contained in the BWX or
MAX extension, the square root and floating-point convert
extension (FIX), and count extension (CIX).
Applications compiled with this option may incur emulation
overhead on ev4, ev5, ev56, ev6, and pca56 processors, but
will still run correctly.
+ -arch pca56
Generates instructions for pca56 processors (21164PC
chips).
This option permits the compiler to generate any EV4
instruction plus any instruction contained in the BWX or
MAX extension.
Applications compiled with this option may incur emulation
overhead on ev4, ev5, and ev56 processors, but will still
run correctly.
-assume backslash
f77 only. Treats the backslash (\) character literally in
character literals. The default is -assume nobackslash, which
treats the backslash character as C-style control (escape)
character syntax.
-assume bigarrays
f90 and f95 only. Suppresses run-time checking for distributed
small array dimensions; this increases run-time performance and
reduces compile time with the -wsf option.
In programs compiled with both the -wsf and -assume bigarrays
options, nearest-neighbor computations that reference small
arrays will fail. An array is big enough when every dimension
that has BLOCK distribution has a shadow edge width that is no
bigger than the block size. The default is -assume nobigarrays.
-assume buffered_io
f90 and f95 only. Tells the compiler to set the default for
opening sequential output files to BUFFERED='YES', so that
writes to disk will be buffered. The default is -assume
nobuffered_io, which means that data will be immediately writ-
ten to disk.
-assume byterecl
Specifies (for unformatted data files) that the units for the
OPEN statement RECL specifier (record length) value are in
bytes, not longwords (four-byte units). For formatted files,
the RECL unit is always in bytes. The default is -assume
nobyterecl.
INQUIRE returns RECL in bytes if the unit is not open. INQUIRE
returns RECL in longwords if the file is open for unformatted
data (and -assume byterecl is not specified); otherwise, it
returns RECL in bytes.
-assume dummy_aliases
Assumes that dummy (formal) arguments to procedures share
memory locations with other dummy arguments or with COMMON
variables that are assigned. These program semantics slow per-
formance and do not strictly obey the FORTRAN 77 Standard. The
default is -assume nodummy_aliases.
-assume gfullpath
f90 and f95 only. Causes the full source file path to be
included in the debug information. The default is -assume nog-
fullpath.
-assume minus0
f90 and f95 only. Tells the compiler to use F95 standard
semantics for the treatment of IEEE floating value -0.0 in the
SIGN intrinsic, if the processor is capable of distinguishing
the difference between -0.0 and +0.0. The default is -assume
nominus0, which tells the compiler to use Fortran 90/77 stan-
dard semantics in the SIGN intrinsic to treat -0.0 and +0.0 as
0.0.
-assume noaccuracy_sensitive
Reorders floating-point operations, based on algebraic identi-
ties (inverses, associativity, and distribution), to improve
performance. The default is -assume accuracy_sensitive.
-assume nosource_include
Tells the compiler to search the default directory for INCLUDE
files (same as when -vms is used). The default is -assume
source_include, which tells the compiler to search the direc-
tory the source file is in for any INCLUDEs.
-assume nounderscore
Does not append a trailing underscore character to external
user-defined names: the main program name, named COMMON, BLOCK
DATA, and names implicitly or explicitly declared EXTERNAL.
The name of blank COMMON remains _BLNK__, and Fortran intrinsic
names are not affected. The default is -assume underscore.
-assume nozsize
f90 and f95 only. Omits run-time checking for zero-sized array
sections for increased performance with the -wsf option. In
programs compiled with both the -wsf and -assume nozsize
options, references to zero-sized array sections cause the exe-
cutable to fail or produce incorrect results. The default is
-assume zsize.
-assume pthreads_lock
f90 and f95 only. Tells the compiler to use restrictive lock-
ing for unnamed critical sections. Other pthreads are also
locked out. The default, -assume nopthreads_lock, is less res-
trictive and much faster. It does not lock out other pthreads,
but provides a single lock for all unnamed critical sections.
-automatic Places local variables on the run-time stack. This option sets
the -recursive option. The default is -noautomatic.
-C Generates code to perform run-time checks on array subscript
and character substring expressions (same as the -check bounds
option). An error is reported if the expression is outside the
dimension of the array or the length of the string. The
default is -check nobounds.
-c Suppresses the loading phase of the compilation and forces an
object file to be produced even if only one program is com-
piled. If you specify multiple files and want full interpro-
cedural optimizations, you must also specify the -o option.
(This creates a single .o file.)
-call_shared
Tells ld(1) to produce a dynamic executable that uses shareable
objects during run-time. The linker searches for unresolved
references in shared library (.so) files before searching in
archive library (.a) files. The run-time loader is invoked to
bring in all required shareable objects and resolve any symbols
that remained undefined during static link-time. This is the
default.
-check bounds
Generates code to perform run-time checks on array subscript
and character substring expressions. An error is reported if
the expression is outside the dimension of the array or the
length of the string. The default is -check nobounds.
-check format
Issues the run-time FORVARMIS fatal error when the data type of
an item being formatted for output does not match the format
descriptor being used (for example, a REAL*4 item formatted
with an I edit descriptor). If -vms is specified, the default
is -check format; otherwise, the default is -check noformat.
With -check noformat, the data item is formatted using the
specified descriptor unless the length of the item cannot
accommodate the descriptor (for example, it is still an error
to pass an INTEGER*2 item to an E edit descriptor).
-check nopower
Suppresses the run-time errors for 0.0**0.0 and
<negative-value>**<integer-value-of-type-real>, so 0.0**0.0 is
1.0 and (-3.0)**3.0 is -27.0. The default is -check power,
which causes fatal run-time errors for these cases.
-check omp_bindings
f90 and f95 only. Provides run-time checking to enforce the
OpenMP binding rules. The default is -check noomp_bindings.
-check output_conversion
Issues the run-time OUTCONERR continuable error message when a
data item is too large to fit in a designated format descriptor
field. The field is filled with asterisks (*) and execution
continues. If -vms is specified, the default is -check
output_conversion; otherwise, the default is -check
nooutput_conversion.
-check overflow
Generates code to trap on integer overflow. The default is
-check nooverflow.
-check underflow
Produces a message at run time to warn that floating-point
underflow has occurred. Floating-point underflow replaces the
result with 0, unless you specify the -fpe3 or -fpe4 option.
The default is -check nounderflow.
-check_bounds
Generates code to perform run-time checks on subscript and sub-
string expressions (same as the -check bounds option). An
error is reported if the expression is outside the dimension of
the array or the length of the string. The default suppresses
range checking.
-col72 Treats the statement field of each source line as ending in
column 72 (same as the -noextend_source option).
-convert Determines which format is used to read and write unformatted
files. The -convert options are described below. For more
information on these options, see your user manual.
The default is -convert native.
The following are -convert options:
+ -convert big_endian
Specifies that unformatted data will be in big endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; and IEEE floating point format of
the appropriate size: REAL*4, REAL*8, COMPLEX*8, or COM-
PLEX*16. Note that INTEGER*1 data is the same for little
endian and big endian.
+ -convert cray
Specifies that unformatted data will be in big endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; and CRAY (TM) floating-point for-
mat of size REAL*8 or COMPLEX*16.
+ -convert fdx
Specifies that unformatted data will be in little endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; Compaq VAX floating-point format
F_floating for size REAL*4 or COMPLEX*8, D_floating for
size REAL*8 or COMPLEX*16, and X_floating for REAL*16.
+ -convert fgx
Specifies that unformatted data will be in little endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; Compaq VAX floating-point format
F_floating for size REAL*4 or COMPLEX*8, floating-point
format G_floating of size REAL*8 or COMPLEX*16, and
X_floating for REAL*16.
+ -convert ibm
Specifies that unformatted data will be in big endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; and IBM (TM) System\370 floating-
point format of size REAL*4 or COMPLEX*8 (IBM short 4) and
size REAL*8 or COMPLEX*16 (IBM long 8).
+ -convert little_endian
Specifies that unformatted data will be in native RISC lit-
tle endian integer format of the appropriate size:
INTEGER*1, INTEGER*2, or INTEGER*4; and IEEE floating-point
format of the appropriate size: REAL*4, REAL*8, REAL*16,
COMPLEX*8, or COMPLEX*16. Note that INTEGER*1 data is the
same for little endian and big endian.
+ -convert native
Specifies that unformatted data should not be converted.
This is the default.
+ -convert vaxd
Specifies that unformatted data will be in little endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; and Compaq VAX floating-point for-
mat F_floating for size REAL*4 or COMPLEX*8, D_floating for
size REAL*8 or COMPLEX*16, and H_floating for REAL*16.
+ -convert vaxg
Specifies that unformatted data will be in little endian
integer format of the appropriate size: INTEGER*1,
INTEGER*2, or INTEGER*4; and Compaq VAX floating-point for-
mat F_floating for size REAL*4 or COMPLEX*8, floating-point
format G_floating of size REAL*8 or COMPLEX*16, and
H_floating for REAL*16.
-cord Runs the cord(1) procedure-rearranger on the resulting file
after linking. This rearrangement reduces the cache conflicts
of the program's text. The output of cord(1) is left in the
file specified by the -o output option (or a.out, by default).
At least one -feedback file must be specified.
-cpp Runs cpp(1) on all Fortran source files before compiling.
-cross_reference
f77 only. Includes in the listing (if one is generated with
-V), a cross-reference of all symbols used in the source pro-
gram, along with line numbers of definitions and uses (same as
the -show xref option). The default is -nocross_reference.
-Dname=def
-Dname Defines the name as def for use by either cpp(1) or Fortran
conditional compilation (f90 and f95 only). def can be an
integer or it can be a character string delimited by double
quotes; for example, -Dname="string". For cpp(1), the defini-
tion is interpreted as if by #define. If no definition is
given, the name is defined as "1".
-double_size 64
Defines DOUBLE PRECISION declarations, constants, functions,
and intrinsics as REAL*8. It also defines DOUBLE COMPLEX
declarations, constants, functions, and intrinsics as COM-
PLEX*16. This is the default.
-double_size 128
Defines DOUBLE PRECISION declarations, constants, functions,
and intrinsics as REAL*16. For f90 and f95, it also defines
DOUBLE COMPLEX declarations, constants, functions, and intrin-
sics as COMPLEX*32. The default is -double_size 64.
-d_lines Compiles lines having a D in column 1 of the source program.
The default is to treat such lines as comments.
-error_limit num
Specifies the maximum number of error-level or fatal-level com-
piler errors allowed for a file specified on the f77 command
line. If you specify -noerror_limit, there is no limit on the
number of errors that are allowed. The default is -error_limit
30 (a maximum of 30 error-level and fatal-level messages).
If -c is specified on the command line and the maximum number
of errors is reached, a warning message is issued and the next
file (if any) on the command line is compiled. If -c is not
specified, a warning message is issued and compilation ter-
minates.
-extend_source
Treats the statement field of each source line as ending in
column 132, instead of column 72. The default is
-noextend_source. For f90 and f95, specifying -extend_source
sets the -fixed option.
-f66 Applies FORTRAN-66 semantics, such as the execution of at least
one iteration of DO loops. This the same as specifying the
-nof77 option. The default is -nof66.
-f77 f77 only. Enforces FORTRAN 77 semantics instead of FORTRAN-66
semantics. For f77, this is the default.
-f77rtl f90 and f95 only. Tells the compiler to use the run-time
behavior of Compaq Fortran 77 instead of Compaq Fortran. For
example, this affects the output form for NAMELIST. The
default is -nof77rtl.
-fast Sets the following command options that can improve run-time
performance: -align dcommons, -arch host, -assume
noaccuracy_sensitive, -math_library fast, -O4 (the default),
and -tune host. For f90 and f95, -fast also sets -align
sequence, -assume bigarrays, and -assume nozsize. The default
is -nofast.
-feedback file
Specifies the file to be used by cord(1) or the compiler for
further optimizations. This file is produced by prof(1) with
its -feedback option from an execution of the program produced
by pixie(1).
-fixed f90 and f95 only. Interprets Fortran source files as fixed
(FORTRAN 77 style) source format. By default, source files with
the suffix .f90, .F90, or .i90 are assumed to be free format
and files with the suffix .f, .for, .FOR, .F, or .i are assumed
to be fixed format.
-fpconstant f90 and f95 only. Extends the precision of single-precision
constants assigned to double-precision variables, to double
precision.
-fpe0 or -fpe
Terminates a program during run time if a floating-point opera-
tion results in overflow, division by zero, or if the operands
are denormalized numbers or other exceptional values. Before
termination, the compiler issues a message, and creates a core
dump file. Calculated denormalized numbers are set to zero.
This is the default.
In the case of floating-point underflow, the program does not
terminate, but continues with the underflow value set to zero.
The compiler issues a warning message if -check underflow is
set.
-fpe1 Continues program execution and generates an Infinity or Nan if
a floating-point operation results in overflow, division by
zero, invalid data, or underflow. Calculated denormalized
numbers are set to zero.
In the case of floating-point underflow, the underflow value is
set to zero. The compiler issues a warning message if -check
underflow is set.
-fpe2 Continues program execution if a floating-point operation
results in overflow, division by zero, invalid data, or under-
flow. Generates a warning message for the first two
occurrences. Calculated denormalized numbers are set to zero.
In the case of floating-point underflow, the underflow value is
set to zero. Upon program completion, the compiler provides a
count of how many times each exception occurred.
-fpe3 Continues program execution if a floating-point operation
results in overflow, division by zero, invalid data, or
underflow. Calculated denormalized numbers are left as is.
For underflow, the underflow value is not set to zero, and gra-
dual underflow occurs. The compiler issues a warning message
if -check underflow is set.
-fpe4 Continues program execution if a floating-point operation
results in overflow, division by zero, invalid data, or under-
flow. Generates a warning message for the first two
occurrences. Calculated denormalized numbers are left as is.
In the case of floating-point underflow, the underflow value is
not set to zero and gradual underflow occurs. Upon program
completion, the compiler provides a count of how many times
each exception occurred.
-fpp Runs fpp(1) on all Fortran files before compiling; it has no
effect on compilation of C programs. fpp(1) handles a subset of
the functionality of cpp(1).
-fprm chopped
Causes the compiler to round results of floating-point opera-
tions toward zero.
-fprm dynamic
Allows run-time selection of a rounding mode by calling the
write_rnd(3) routine. The read_rnd(3) routine can be used to
find the current rounding mode (which is stored in the
floating-point control register (fpcr)).
If you specify -fprm dynamic without calling the write_rnd(3)
routine, the default setting ( -fprm nearest ) is used.
-fprm minus_infinity
Causes the compiler to round results of floating-point opera-
tions toward the next smallest representative value.
-fprm nearest
Causes the compiler to round results of floating-point opera-
tions toward the nearest representable value. This is the
default.
If the unrounded value is halfway between two representable
values, the even value is chosen.
-fp_reorder Reorders floating-point operations, based on algebraic identi-
ties (inverses, associativity, and distribution), to improve
performance. The default is -no_fp_reorder. This option is the
same as the -assume noaccuracy_sensitive option.
-free f90 and f95 only. Interprets Fortran source files as free
source format. By default, source files with the suffix .f90,
.F90, or .i90 are assumed to be free format and files with the
suffix .f, .for, .FOR, .F, or .i are assumed to be fixed for-
mat.
-fuse_xref f90 and f95 only. Directs the compiler to generate a data file
that the DEC FUSE Database Manager uses to create a cross-
reference database file. This improves the performance of the
DEC FUSE Call Graph Browse and Cross-Referencer, which use the
database file for their operations.
-g0 Prevents symbolic debugging information from appearing in the
object file.
-g1 Produces traceback information (showing pc to line correlation)
in the object file, substantially increasing its size. This is
the default.
-g2 or -g Produces traceback and symbolic debugging information in the
object file. Unless an explicit optimization level has been
specified, these options set the -O0 option, which turns off
all compiler optimizations and makes debugging more accurate.
-g3 Produces traceback and symbolic debugging information in the
object file, but does not set an optimization level. This
option can produce additional debugging information describing
the effects of optimizations, but debugger inaccuracies can
occur as a result of the optimizations that have been per-
formed.
-gen_feedback
Directs the compiler to generate code that will produce accu-
rate feedback information when profiled. The steps are:
1. f77 -gen_feedback -o x x.f
2. pixie x
3. x.pixie
4. prof x -pixie -feedback x.fb x.Addrs x.Counts
5. f77 -feedback x.fb -O5 -fast -o x x.f
-granularity byte
Ensures that data of byte size can be accessed from different
threads sharing data in memory. The data must be aligned on
the natural boundary and declared VOLATILE.
-granularity longword
Ensures that naturally aligned data of longword size (4 bytes)
can be accessed from different threads sharing data in memory.
The data must be aligned on the natural boundary and declared
VOLATILE.
When this option is in effect, attempts to access smaller size
data or misaligned data can result in data items that are
inconsistently updated for multiple threads.
-granularity quadword
Ensures that naturally aligned data of quadword size (8 bytes)
can be accessed from different threads sharing data in memory.
The data must be aligned on the natural boundary and declared
VOLATILE. This is the default.
When this option is in effect, attempts to access smaller size
data or misaligned data can result in data items that are
inconsistently updated for multiple threads.
-hpf_matmul f90 and f95 only. Uses the matrix multiplication routine from
the hpf library. This routine is only used in serial (non
-wsf) compilations.
-I Prevents cpp(1) from searching for #include files in the stan-
dard directory /usr/include. It also prevents the compiler
from searching there for files specified in an INCLUDE state-
ment. This option is not related to the Fortran 90 and 95 USE
statement.
-Idir Directs the search for cpp(1) #include files, files specified
in an INCLUDE statement, and files (.mod) for Fortran 90 and 95
module information. The file names must not begin with slash
(/).
Directories are searched in the following order: (1) the direc-
tory preceding the input file name on the command line; (2) the
directory specified by the -Idir option; (3) the standard
directory /usr/include. (See also the -noinclude option.)
-i2 Makes default integer and logical variables 2-bytes long (same
as the -integer_size 16 option). The default is -integer_size
32. For optimal performance on Alpha systems, use 4- or 8-byte
integer or logical values instead of 2-byte values.
-i4 Makes default integer and logical variables 4-bytes long (same
as the -integer_size 32 option). This is the default.
-i8 Makes default integer and logical variables 8-bytes long (same
as the -integer_size 64 option). The default is -integer_size
32.
-ident f77 only. Specifies that what(1) style identification strings
should be placed in the .o object file. The formats of the
strings are:
(c)compiler-identification
(m)module-name
(d)date
These strings are always created for Fortran main programs, and
when the CDEC$ IDENT statement in source creates a what(1)
module identification string. The default is -noident.
-inline all Inlines every procedure call that can be inlined while still
generating correct code. However, recursive routines will not
cause an infinite loop at compile time.
This option is meaningful only at optimization levels -O1 and
higher.
-inline manual
For f77, inlines only statement functions. This is the default
for optimization levels -O2 and -O3.
For f90 and f95, this is the same as the -inline none option.
-inline none
Suppresses all inlining of routines (same as the -noinline
option).
For f77, this is the default for optimization levels -O0 and
-O1. For f90 and f95, this is the default for optimization
levels -O0, -O1, -O2, and -O3.
-inline size
Inlines calls where inlining will not significantly increase
program size, plus any additional calls that the compiler
determines will improve run-time performance. This option was
previously called -inline automatic (and -inline space ).
This option is meaningful only at optimization levels -O1 and
higher.
-inline speed
Inlines calls that will likely improve run-time performance,
even where it may significantly increase the size of the
program. This is the default for optimization levels -O4 and
-O5. This option is meaningful only at optimization levels -O1
and higher.
-intconstant
f90 and f95 only. Uses FORTRAN 77 rather than Fortran 90
semantics to determine kind for integer constants.
-integer_size 16
Makes default integer and logical variables 2-bytes long. The
default is -integer_size 32. For optimal performance on Alpha
systems, use 4- or 8-byte integer or logical values instead of
2-byte values.
-integer_size 32
Makes default integer and logical variables 4-bytes long. This
is the default.
-integer_size 64
Makes default integer and logical variables 8-bytes long. The
default is -integer_size 32.
-K Keeps temporary files produced by cpp(1). This option does not
affect the naming of temporary files. To see the names and
locations of the temporary files, specify -v.
-L Prevents the linker from searching for libraries in the stan-
dard directories.
-Ldir Directs the linker to search for libraries in dir before
searching the standard directories.
-lstring Searches libstring libraries for ld (see ld(1)). This option
should be placed at the end of the command line.
-ladebug f90 and f95 only. Includes additional symbolic information in
the object file for the ladebug(1) debugger. This option
enables DECladebug to print and assign to dynamic arrays using
standard Fortran syntax, including array sections.
-M Tells cpp(1) to generate dependency lists suitable for make(1),
instead of the normal output.
-machine_code
Includes in the listing (if one is generated) a machine
language representation of the compiled code. This machine
language cannot be assembled. This option is the same as -show
code. The default is -nomachine_code.
-math_library accurate
Specifies that the compiler is to select the version of the
math library routine which provides the most accurate result
for mathematical intrinsic functions. This is the default.
For certain ranges of input values, the selected routine may
execute more slowly than if you used -math_library fast.
-math_library fast
Specifies that the compiler is to select the version of the
math library routine which provides the highest execution per-
formance for certain mathematical intrinsic functions, such as
EXP and SQRT.
For certain ranges of input values, the selected routine may
not provide a result that is as accurate as -math_library accu-
rate (the default setting) provides.
-mixed_str_len_arg
Tells the compiler that the hidden length passed for a charac-
ter argument is to be placed immediately after its correspond-
ing character argument in the argument list. The default is
-nomixed_str_len_arg, which places the hidden lengths in
sequential order at the end of the argument list.
-module directory
f90 and f95 only. Outputs .mod files to directory.
-mp f90 and f95 only. Enables parallel processing using directed
decomposition. Parallel processing is directed by inserting
!$PAR directives in your source code. This type of parallel
processing is for shared memory multiprocessor systems. The
default is -nomp.
-names as_is
Causes the compiler to distinguish case differences in identif-
iers and to preserve the case of external names. The default
is -names lowercase.
-names lowercase
Causes the compiler to ignore case differences in identifiers
and to convert external names to lowercase. This is the
default.
-names uppercase
Causes the compiler to ignore case differences in identifiers
and to convert external names to uppercase. The default is
-names lowercase.
-nearest_neighbor num
f90 and f95 only. Enables the nearest neighbor parallel optim-
ization. The optional num parameter specifies the maximum width
of the shadow edge to use. If num is not specified, it is set
to 10 (the default). This option is only valid if the -wsf
option is specified.
-noaltparam Disallows the alternate non-standard syntax for PARAMETER
statements. This form has no parentheses surrounding the list,
and the form of the constant, rather than implicit or explicit
typing, determines the data type of the variable. The default
is -altparam.
-nocpp Does not run cpp(1) on any Fortran source files before compil-
ing.
-noD f90 and f95 only. Tells the driver not to pass any -Dname or
-Uname options to the compiler. The default is to pass these
to the compiler. These options are always passed to cpp(1).
-noerror_limit
Specifies that there is no limit to the number of error-level
or fatal-level compiler errors allowed for a file specified on
the command line.
-nof77 Allows extensions that enhance FORTRAN-66 compatibility. This
option is the same as the -f66 option.
-nofor_main Specifies that the main program is not written in Fortran, and
prevents the compiler from linking for_main.o into applica-
tions. The default is -for_main.
-nofpp Does not run fpp(1) (or cpp(1)) on Fortran source files before
compiling.
-no_fp_reorder
This option is the same as the -assume accuracy_sensitive
option.
-noi4 Makes default integer and logical variables 2-bytes long (same
as the -integer_size 16 option). For optimal performance on
Alpha systems, use 4- or 8-byte integer or logical values
instead of 2-byte values.
-noinclude Prevents the compiler from searching in /usr/include for files
specified in a Compaq Fortran INCLUDE statement. You can
specify the -Idir option along with this option. This option
does not affect cpp(1) behavior, and is not related to the For-
tran 90 and 95 USE statement.
-non_shared Prevents ld(1) from producing a dynamic executable. The linker
will search regular archive library (.a) files to resolve unde-
fined references; .so files are not searched. Object files
(.o suffix) from archives are included in the executable pro-
duced. The default is -call_shared.
-nonearest_neighbor
f90 and f95 only. Disables the nearest neighbor parallel
optimization.
-nopipeline Disables the use of instruction scheduling for certain inner-
most loops. Also disables prefetching of data to reduce the
impact of cache misses.
This option must be specified if you want this type of optimi-
zation disabled and you are also specifying -O5, since -pipe-
line is performed by default at the -O5 level of optimization.
-norun Directs the driver not to execute the compiler and other phases
of the process. If you use this option with the -v option, you
can see what would have been executed.
-notransform_loops
Disables a group of loop transformation optimizations that
apply to array references within loops. This group of optimi-
zations includes loop blocking, loop distribution, loop fusion,
loop interchange, loop scalar replacement, and outer loop
unrolling.
This option must be specified if you want this type of optimi-
zation disabled and you are also specifying -O5, since
-transform_loops is performed by default at the -O5 level of
optimization.
-nowsf_main f90 and f95 only. Specifies that the HPF global routine being
compiled will be linked with a main program that was not com-
piled with -wsf. The main program can be a Fortran program
compiled without -wsf, or it can be written in an entirely dif-
ferent language.
-O0 Disables all optimizations. Does not check for unassigned vari-
ables.
-O1 Enables local optimizations and recognition of common subex-
pressions. Optimizations include integer multiplication and
division expansion using shifts. The call graph determines the
order of compilation of procedures.
-O2 Enables global optimization and all -O1 optimizations. This
includes code motion, strength reduction and test replacement,
split lifetime analysis, code scheduling, and inlining of
arithmetic statement functions.
-O3 Enables global optimizations that improve speed at the cost of
increased code size, and all -O2 optimizations. Optimizations
include integer multiplication and division expansion (using
shifts), loop unrolling, and code replication to eliminate
branches. (See also the -unroll option.)
-O4 or -O Enables inline expansion of small procedures and all -O3 optim-
izations. This is the default. However, if you specify the -g
option, the default is -O0. (See also the -g2 or -g option,
and the -inline option.)
-O5 Enables software pipelining, loop transformation optimizations,
and other optimizations, including byte-vectorization, and
insertion of additional NOPs (No Operations) for alignment of
multi-issue sequences. (See also the -speculate options.)
Loop transformation optimizations are a group of optimizations
that apply to array references within loops. These optimiza-
tions can improve the performance of the memory system and can
apply to multiple nested loops. This type of optimization can
also be specified by using the -transform_loops option. (See
also the -transform_loops option.)
Software pipelining applies instruction scheduling to certain
innermost loops, allowing instructions within a loop to "wrap
around" and execute in a different iteration of the loop. This
can reduce the impact of long-latency operations, resulting in
faster loop execution. This type of optimization can also be
specified by using the -pipeline option. (See also the -pipe-
line option.)
To determine whether using -O5 benefits your particular pro-
gram, time program execution for the same program compiled with
-O4 and -O5.
-o output Names the final output file output. The a.out file is unaf-
fected.
-old_f77 f77 only. Tells the f77 driver to execute the Compaq Fortran
77 compiler instead of the Compaq Fortran ( f90 ) compiler.
-old_f77 must be the first option on the f77 command line. The
default is for the f77 command to execute the f90 compiler and
use the f90 environment variables.
The f77 command now executes the Compaq Fortran 90 compiler by
default. If you want to use the Compaq Fortran 77 compiler,
you must use the -old_f77 option with the f77 command.
-om Performs code optimization after linking, including NOP (No
Operation) removal, .lita removal, and reallocation of common
symbols. This option also positions the global pointer register
so the maximum addresses fall in the gp-accessible window. The
-om option is supported only for programs compiled with the
-non_shared option.
The following options can be passed directly to -om by using
the -WL compiler option:
+ -WL,-om_compress_lita
Removes unused .lita entries after optimization, and then
compresses the .lita section.
+ -WL,-om_dead_code
Removes dead code (unreachable instructions) generated
after applying optimizations. The .lita section is not
compressed by this option.
+ -WL,-om_no_inst_sched
Turns off instruction scheduling.
+ -WL,-om_no_align_labels
Turns off alignment of labels. Normally, the -om option
quadword aligns the targets of all branches to improve loop
performance.
+ -WL,-om_Gcommon,num
Sets the size threshold of common symbols. Every common
symbol whose size is less than or equal to "num" will be
allocated close to each other. This option can be used to
improve the probability that the symbol can be accessed
directory from the global pointer register. Normally, the
-om option tries to collect all common symbols together.
-omp f90 and f95 only. Enables parallel processing using directed
decomposition following the OpenMP application program inter-
face (API). Parallel processing is indicated by inserting
!$OMP directives in your source code. This type of parallel
processing is for shared memory multiprocessor systems. The
default is -noomp.
-onetrip Executes at least one iteration of DO loops. (FORTRAN 77 DO
loops are not executed if the upper limit is smaller than the
lower limit.) This option has the same effect as -nof77.
-P Runs only cpp(1) and puts the result for each source file in a
corresponding .i (or Fortran 90 .i90) file, after processing by
any appropriate preprocessors. The .i (or .i90) file does not
have line numbers (#) in it. This option sets the -cpp option.
-p0 Does not permit profiling. If loading occurs, the standard
run-time startup routine (crt0.o) is used, and the profiling
libraries are not searched. This is the default.
-p1 or -p Sets up profiling by periodically sampling the value of the
program counter for use with the postprocessor prof(1). This
option only effects loading. When loading occurs, this option
replaces the standard run-time startup routine with the profil-
ing run-time startup routine (mcrt0.o) and searches the level 1
profiling library (libprof1.a).
When profiling occurs, the startup routine calls monstartup(3)
(see monitor(3)) and produces the file mon.out, which contains
execution-profiling data for use with the postprocessor
prof(l). If you specify -p1 or -p, you should also specify -g1
or higher.
-pad_source Specifies that source records shorter than the statement field
width are to be padded with spaces on the right, out to the end
of the statement field. This affects the interpretation of
character and Hollerith literals that are continued across
source records. The default is -nopad_source.
-pg Sets up profiling for gprof(1), which produces a call graph
showing the execution of the program. With this option, the
standard run-time startup routine is replaced by the gcrt0.o
routine, and ld(1) inserts calls to _mcount at each entry
label.
Programs that are linked with the -pg option and then run, pro-
duce the files gmon.out and gmon.sum. File gmon.out contains a
dynamic call graph and profile; file gmon.sum contains a sum-
marized dynamic call graph and profile. To display the output,
run gprof on the gmon.out file.
-pipeline Applies instruction scheduling to certain innermost loops,
allowing instructions within a loop to "wrap around" and exe-
cute in a different iteration of the loop. This can reduce the
impact of long-latency operations, resulting in faster loop
execution. This option also enables prefetching of data to
reduce the impact of cache misses.
It may increase compilation time and/or program size. For pro-
grams that contain loops that exhaust available registers,
longer execution times may occur. In this case, specify
options -unroll 1 or -unroll 2 with the -pipeline option.
This option is meaningful only at optimization levels -O2 and
higher; it is performed by default if level -O5 is in effect.
-pprof string
f90 and f95 only. Profiles a parallel application. This
option is valid only if options -wsf and -non_shared are speci-
fied, and the -p1 option is not specified. The string can be
either of two profiling methods:
s - sampling
i - interval
-pthread Informs the linker to use threaded libraries (see also -reen-
trancy keyword options). This option is the same as the
-threads option.
-r8 Defines REAL declarations, constants, functions, and intrinsics
as DOUBLE PRECISION (REAL*8), and defines COMPLEX declarations,
constants, functions, and intrinsics as DOUBLE COMPLEX (COM-
PLEX*16). This option is the same as the -real_size 64 option.
-r16 Defines REAL and DOUBLE PRECISION declarations, constants,
functions, and intrinsics as REAL*16. For f90 and f95, it also
defines COMPLEX and DOUBLE COMPLEX declarations, constants,
functions, and intrinsics as COMPLEX*32. This option is the
same as the -real_size 128 option.
-real_size 32
Defines REAL declarations, constants, functions, and intrinsics
as REAL*4, and defines COMPLEX declarations, constants, func-
tions, and intrinsics as COMPLEX (COMPLEX*8). This is the
default.
-real_size 64
Defines REAL declarations, constants, functions, and intrinsics
as DOUBLE PRECISION (REAL*8), and defines COMPLEX declarations,
constants, functions, and intrinsics as DOUBLE COMPLEX (COM-
PLEX*16). The default is -real_size 32.
-real_size 128
Defines REAL and DOUBLE PRECISION declarations, constants,
functions, and intrinsics as REAL*16. For f90 and f95, it also
defines COMPLEX and DOUBLE COMPLEX declarations, constants,
functions, and intrinsics as COMPLEX*32. The default is
-real_size 32.
-recursive Compiles all FUNCTION and SUBROUTINE procedures for possible
recursive execution. The default is -norecursive. For f90 and
f95, this option sets the -automatic option.
-reentrancy asynch
Tells the Compaq Fortran RTL that the program may contain asyn-
chronous (AST) handlers that could call the RTL. This causes
the RTL to guard against AST interrupts inside its own critical
regions.
-reentrancy none
Tells the Compaq Fortran RTL that the program will not be rely-
ing on threaded or asynchronous (AST) reentrancy. So, the RTL
will not guard against such interrupts inside the RTL. This is
the default. This option is the same as the -noreentrancy
option.
-reentrancy threaded
Tells the Compaq Fortran RTL that the program is multithreaded,
such as programs using the DECthreads library. This causes the
RTL to use thread locking to guard its own critical regions.
-S Creates an assembleable listing file of the compiled source.
The name of this listing file is the base name of the source
file with a .s substituted for the .f90, .F90, .f, .for, .FOR,
or .F. No link step occurs.
You cannot generate a -S listing and a -V or -source_listing
listing in the same compilation.
-shared Produces a dynamic shareable object for inclusion in a shared
library. This includes creating all of the tables for run-time
linking and resolving references to other specified shared
objects. The object created can be used by the linker to pro-
duce a shareable object that other dynamic executables can use
at run-time.
If you also specify the -c option, a .o file is created; other-
wise, a .so file is created. The default is -call_shared.
-show code Includes in the listing (if one is generated) a machine
language representation of the compiled code (same as the
-machine_code option). This machine language cannot be assem-
bled. The default is -show nocode.
-show hpf[option]
f90 and f95 only. Sends information related to parallelization
to standard error and to the listing (if one is generated).
These options are not valid unless the option -wsf is also in
effect.
The following options are available:
+ -show hpf
Includes a selected subset of the messages generated by all
the other -show hpf_* options.
It is usually best to try using this option first. Use the
others only when a more detailed listing is needed.
+ -show hpf_comm
Includes information about statements which cause interpro-
cessor communication to be generated.
+ -show hpf_indep
Includes information about the optimization of loops marked
with the INDEPENDENT directive.
+ -show hpf_nearest
Includes information about arrays and statements involved in
optimized nearest-neighbor computations.
+ -show hpf_punt
Includes information about distribution directives that were
ignored and statements that were not handled in parallel.
+ -show hpf_temps
Includes information about temporaries that were created at
procedure interfaces.
+ -show hpf_all
This option is the same as specifying all the other -show
hpf_* options.
-show can take only one argument. However, the -show options
can be combined by specifying -show multiple times. For exam-
ple:
% f90 -wsf -show hpf_near -show hpf_comm -show hpf_punt foo.f90
-show include
Includes in the listing (if one is generated) any text file
specified with INCLUDE in the source program. The default is
-show noinclude.
-show nomap Excludes from the listing (if one is generated) information
about the symbols used in the source program. The default is
-show map.
-show wsfinfo
f90 and f95 only. This option is the same as -show hpf_all.
-show xref f77 only. Includes in the listing (if one is generated) a
cross-reference of all symbols used in the source program,
along with line numbers of definitions and uses (same as the
-cross_reference option). The default is -show noxref.
-source_listing
Creates a source listing file with various compile-time infor-
mation appended, like -V. The name of the listing file is the
basename of the source file with a .lis suffix. The default is
-nosource_listing.
-speculate all
Performs speculative execution optimization on all routines in
the program.
Speculation occurs when a conditionally executed instruction is
moved to a position before a test instruction so that the moved
instruction is then executed unconditionally. This reduces
instruction latency stalls, but performance can be reduced
because the run-time system must dismiss exceptions caused by
speculative instructions.
Speculation affects code most noticeably at optimization levels
-O3 and higher.
Any exception (for example: SIGSEGV, SIGBUS, or SIGFPE), any-
where in the entire program, is assumed to be speculative. All
of these exceptions are quietly dismissed without calling any
user-mode signal handler. If a module is compiled using
-speculate all, it cannot be linked with any other module or
library that does its own exception processing.
Since speculation turns off some run-time error checking, this
option should not be used while debugging or while testing for
errors. The default is -speculate none.
-speculate by_routine
Performs speculative execution optimization on all routines in
the current module, but this optimization will not effect rou-
tines in other modules in the program. Requires DIGITAL UNIX
Version 4.0 or higher.
-speculate none
Suppresses all speculative execution optimization (same as the
-nospeculate option). This is the default.
-stand mia f77 only. Controls whether the compiler suppresses diagnostic
messages for extensions to the ANSI FORTRAN 77 standard that
are included in the NTT Technical Requirement TR550001, Mul-
tivendor Integration Architecture (MIA) Version 1.1, Division
2, Part 3-2, Programming Language FORTRAN. This option enables
syntax checking ( -stand syntax ) to be performed. The default
is -stand nomia.
-stand semantic
f77 only. Causes the compiler to issue informational messages
for statements that conform to the ANSI Standard but become
nonstandard because of how they are used. This option sets the
-stand syntax option. The default is -stand nosemantic.
-stand source_form
f77 only. Causes the compiler to issue informational messages
for statements that use tab formatting or contain lowercase
characters outside of character literals and comments. The
default is -stand nosource_form.
-stand syntax
f77 only. Causes the compiler to issue informational messages
for syntax extensions to the ANSI Standard. The default is
-stand nosyntax.
-static Causes all local variables to be statically allocated (same as
the -noautomatic option). This is the default.
-std Produces warnings for things that are not standard in the
language. The default is -nostd. For f77, specifying -std is
the same as specifying options -stand semantic -stand syntax.
When -std is specified, the compiler being used determines the
standard checked; for example: specifying "f95 -std" is the
same as specifying "f90 -std95".
-std90 f90 and f95 only. Produces warnings for things that are not
standard in the Fortran 90 language.
-std95 f90 and f95 only. Produces warnings for things that are not
standard in the Fortran 95 language.
-synchronous_exceptions
Causes the compiler to generate TRAPB instructions after every
floating-point instruction. -fpe0 must also be enabled.
This is a very expensive but effective way to synchronize the
instruction stream containing floating-point exceptions so the
failing instruction can be accurately located by the debugger
or a handler. The default is -nosynchronous_exceptions.
-syntax_only
Specifies that the source file will be checked only for correct
syntax. No code is generated, no object file is produced, and
some error checking done by the optimizer is bypassed (for
example, checking for uninitialized variables). This option
lets you do a quick syntax check of your source file. The
default is -nosyntax_only.
-threads Informs the linker to use threaded libraries (see also -reen-
trancy keyword options). This option is the same as the
-pthread option.
-transform_loops
Specifies a group of loop transformation optimizations that
apply to array references within loops. These optimizations can
improve the performance of the memory system and usually apply
to multiply nested loops.
These optimizations include:
Loop blocking
Loop distribution
Loop fusion
Loop interchange
Loop scalar replacement
Outer loop unrolling
The loops chosen for loop transformation optimizations are
always "counted" loops (which include DO or IF loops, but not
DO WHILE loops).
Conditions that typically prevent the loop transformation
optimizations from occurring include subprogram references that
are not inlined (such as an external function call), compli-
cated exit conditions, and uncounted loops.
This type of optimization can be specified for optimization
levels -O2 and higher; it is performed by default if -O5 is in
effect.
To determine whether using -transform_loops benefits your par-
ticular program, you should time program execution for the same
program (or subprogram) compiled at -O4.
-tune Selects processor-specific instruction tuning for implementa-
tions of the Alpha architecture. The format is:
-tune generic | host | ev4 | ev5 | ev56 | ev6 | ev67 | pca56
Regardless of the setting of the -tune option, the generated
code will run correctly on all implementations of the Alpha
architecture. Tuning for a specific implementation can improve
run-time performance; it is also possible that code tuned for
a specific target may run slower on another target. The fol-
lowing are -tune options:
+ -tune generic
Selects instruction tuning that is appropriate for all
implementations of the Alpha architecture. This is the
default.
+ -tune host
Selects instruction tuning that is appropriate for the
machine the compilation is occurring on.
+ -tune ev4
Selects instruction tuning for the 21064, 20164A, 21066,
and 21068 implementations of the Alpha architecture.
+ -tune ev5
Selects instruction tuning for the 21164 implementation of
the Alpha architecture.
+ -tune ev56
Selects instruction tuning for ev56 processors (some 21164
chips).
+ -tune ev6
Selects instruction tuning for ev6 processors (21264
chips).
+ -tune ev67
Selects instruction tuning for ev67 processors (21264A
chips).
+ -tune pca56
Selects instruction tuning for pca56 processors (21164PC
chips).
-U Causes the compiler to distinguish between uppercase and lower-
case letters in identifiers and external names. This option is
the same as the -names as_is option.
-Uname Tells cpp(1) to remove any initial definition of name.
-u Sets the default type of a variable as undefined (IMPLICIT
NONE), which causes the compiler to issue a warning for any
undeclared symbols (same as the -warn declarations option).
This behavior differs from default FORTRAN 77 rules.
-unroll num Sets the depth of loop unrolling done by the optimizer (at lev-
els -O3 and above) to num. It must be an integer in the range 0
through 16. -nounroll is not allowed. The default is -unroll 0
(where the optimizer uses its default unroll amount).
-V Creates a source listing file with various compile-time infor-
mation appended. The name of the listing file is the basename
of the source file with a .l suffix. The default is -noV.
How you compile source files determines how the listing file is
created. If you compile several source files together, one
listing file is created (named with the basename of the first
input file and the .l suffix). If you compile source files one
at a time, a separate listing file is created for each input
file (named with the basename of the input file and the .l suf-
fix).
-v Prints the passes as they execute with their arguments and
their input and output files. Also prints final resource usage
in the C-shell time format. The default is -nov.
-version f90 and f95 only. Prints the compiler version number. The
default is -noversion.
-vms Causes the run-time system to behave like Compaq Fortran on
OpenVMS VAX systems (VAX FORTRAN) in the following ways:
+ Reinforces certain defaults
Reinforces the following Compaq Fortran 77 defaults: -fpe0,
-static, -names lowercase (so A is equivalent to a), and
-norecursive. You can override this by specifying the
option on the command line. For example, if you specify
-vms -fpe2, you get -fpe2. The -vms option also forces
-check format and -check output_conversion.
+ Alignment
-vms does not affect the alignment of fields in records or
items in COMMON. Use -align norecords to pack fields of
records on the next byte boundary for compatibility with
Compaq Fortran on OpenVMS VAX systems.
+ INCLUDE qualifiers
Recognizes /LIST and /NOLIST at the end of the file path-
name in an INCLUDE statement at compile time.
If the file name in the INCLUDE statement does not specify
the complete path, the path used is the current directory.
+ Quotation mark character (")
Recognizes a quotation mark as starting an octal constant
(such as "177) instead of a character literal ("...").
+ Control character syntax
Does not recognize the \n control character syntax in char-
acter literals (same as the -assume backslash option).
+ Deleted records in relative files
When a record in a relative file is deleted, the first byte
of that record is set to a known character (currently '@').
Attempts to read that record later result in ATTACCNON
errors. The rest of the record (the whole record, if -vms
is not set) is set to nulls for unformatted files and
spaces for formatted files.
+ ENDFILE records
When an ENDFILE is performed on a sequential unit, an
actual one byte record containing a Ctrl/D is written to
the file. If -vms is not set, an internal ENDFILE flag is
set and the file is truncated.
The -vms option does not affect ENDFILE on relative files;
such files are truncated.
+ Reading deleted records and ENDFILE records
The run-time direct access READ routine checks the first
byte of the retrieved record. If this byte is '@' or NULL
("\0"), then ATTACCNON is returned.
The run-time sequential access READ routine checks to see
if the record it just read is one byte long and contains a
Ctrl/D. If this is true, it returns EOF.
+ OPEN effects
Carriage control defaults to FORTRAN if the file is format-
ted, and the unit is connected to a terminal (checked by
means of isatty(3) ). Otherwise, carriage control defaults
to LIST.
The -vms option affects the record length for direct access
and relative organization files. The buffer size is
increased by one (to accommodate the deleted record charac-
ter).
+ Implied logical unit numbers
Recognizes certain environment variables at run time for
ACCEPT, PRINT, and TYPE statements, and for READ and WRITE
statements that do not specify a unit number, such as: READ
(*,1000). For more information, see your user manual.
+ Treatment of blanks in input
Causes the defaults for keyword BLANK in OPEN statements to
become 'NULL' for an explicit OPEN, and 'ZERO' for an
implicit OPEN of an external or internal file.
-Wl,arg1[,arg2]...
Passes options arg1[ arg2]... to cc(1) for ld(1).
-Wp,arg1[,arg2]...
Passes options arg1[ arg2]... to cpp(1) that the driver does
not normally pass to the preprocessor. For example: -Wp,-C,-M
passes -C -M to cpp(1). -Wp,... does not invoke cpp(1); use
-cpp to force the execution of cpp(1).
-w Disables all warning messages (same as the -nowarn and -warn
-nogeneral options).
-w1 Disables warnings about unused variables (same as the -warn
nounused option).
-warn argument_checking
Enables warnings about mismatched procedure arguments. The
default is -warn noargument_checking.
-warn declarations
Sets the default type of a variable as undefined (IMPLICIT
NONE), which enables warnings about any undeclared symbols.
This behavior differs from default FORTRAN 77 rules. The
default is -warn nodeclarations.
-warn hpf f90 and f95 only. Tells the compiler to do both syntactic and
semantics checking on HPF directives. The default is -warn
nohpf, unless -wsf is specified, in which case -warn hpf is
assumed.
-warn noalignments
Disables warnings about data that is not naturally aligned.
The default is -warn alignments.
-warn nogeneral
Disables all warning messages (same as the -nowarn and -w
options). The default is -warn general.
-warn nogranularity
f90 and f95 only. Disables warnings when the compiler cannot
generate code for a requested granularity. The default is
-warn granularity.
-warn noinformational
f77 only. Disables all informational messages. The default is
-warn informational, unless you also specify -warn nogeneral.
In this case, no warning or informational messages are
displayed.
-warn nouncalled
Disables warnings about a statement function that is never
called. The default is -warn uncalled.
-warn nouninitialized
Disables warnings about a variable that is used before a value
is assigned to it. The default is -warn uninitialized.
-warn nounreachable
f77 only. Disables warnings about a section of code that is
unreachable (no path to it). The default is -warn unreachable.
-warn nousage
Disables warnings about questionable programming practices
which, although allowed, often are the result of programming
errors. For example, a continued character or Hollerith
literal whose first part ends before the statement field and
appears to end with trailing spaces. The default is -warn
usage.
-warn truncated_source
Enables warnings at compile time about source characters to the
right of column 80 (or column 132 if -extend_source is speci-
fied) in a non-comment line. The default is -warn
notruncated_source.
-warn unused
Enables warnings about unused variables. The default is -warn
nounused.
-warning_severity error
f90 and f95 only. Turns all messages that are normally warn-
ings into errors.
-warning_severity stderror
f90 and f95 only. Issues an error message instead of a warning
for standard violations. Standard violations are detected when
the -std option is specified.
-what Prints the version strings of the Fortran command and the com-
piler. If -what appears alone on the command line, the com-
piler is not executed.
-wsf [num] f90 and f95 only. Compiles the program to run in parallel
using the Compaq Parallel Software Environment. The optional
num parameter specifies the number of processors on which the
program is intended to execute. If a number is not specified,
the program will be compiled to execute on any number of pro-
cessors. More efficient code is generated when num is speci-
fied.
The following options are relevant to the -wsf option ( for
more information on these options, see the Compaq High Perfor-
mance Fortran 90 HPF and PSE Manual ):
-assume bigarrays
-assume nozsize
-fast
-nearest_neighbor
-nowsf_main
-pprof
-show hpf
The following options are not compatible with the -wsf option:
-cord, -double_size 128, -feedback, -fpe1, -fpe2, -fpe3, -fpe4,
-gen_feedback, -om, -p1, (or -p), -pg.
The -C (or -check_bounds or -check bounds) option is compatible
with the -wsf option only when optional parameter num is set to
1.
The driver ignores the following options and displays an informative mes-
sage saying they are unsupported:
-align8
-align16
-align32 Allows misalignment in COMMON.
-col120 Truncates source after column 120.
-q Does not display file and program names.
-w66 Suppresses F66 compatibility warnings.
The driver does not process the following options, but passes them to the
cc(1) compiler:
-D num Tells ld(1) to set the data segment origin. If num starts with
a hexadecimal letter, precede it with the digit "0".
-fptm x Tells cc(1) how to support exception handling (on Tru64 UNIX
systems only).
-ko output Tells cc(1) the name for the output file created by ucode
loader.
-N... Tells cc(1) to enlarge static tables.
-Olimit num Tells cc(1) to NOOPT if a routine is too big.
-qlx Tells ld(1) about optional -l libraries.
-systype name
Names compilation environment (on ULTRIX RISC systems only).
-T num Tells ld(1) to set the text segment origin. If num starts with
a hexadecimal letter, precede it with the digit "0".
-taso Helps port programs that assume addresses can fit into 32-bit
variables.
-W... Passes command line options to other phases of the compilation
process.
f77 stops compilation if the following option is specified:
-EB Produces big endian byte order.
The driver assumes other arguments are either loader options or Fortran-
compatible object files, typically produced by an earlier compilation, or
libraries of Fortran-compatible routines. These files, together with the
results of any compilations specified, are loaded in the order given, pro-
ducing an executable program with the default name a.out.
The f90, f95, and f77 compilers recognize several DEC C options and convert
them to appropriate compiler options, for example:
C option seen by driver Option sent to the compiler
-fp_reorder -assume noaccuracy_sensitive
-ieee_with_no_inexact -fp3
-nomember_alignment -align norecord
-no_fp_reorder -assume accuracy_sensitive
-Oaggressive -fast
Restrictions
The standard libraries, like libc, are loaded with the -l loader option and
not a full pathname. The wrong library can be loaded if there are files
with names like libc.a or libc.so in the directories specified with the -L
loader option, or in the default directories searched by the loader.
For f90 and f95, when multiple source files are compiled together without
the -c option, the first source file's suffix determines the default source
form for the entire compilation.
Diagnostics
The f90, f95, and f77 commands produce diagnostic messages that are
intended to be self-explanatory. The loader can also produce occasional
messages.
Files
a.out Loaded output
file.f f77 input file
file.f90 f90 input file
file.o Object file
mon.out File produced for analysis by prof(1)
pprof#.out File produced for analysis by pprof(1)
/tmp/for* Temporary
/usr/bin/f77 Link to f77 command processor
/usr/bin/f90 Link to f90 command processor
/usr/bin/f95 Link to f95 command processor
/usr/bin/fpr Formats Fortran carriage-control list-
ings for printing
/usr/bin/fsplit Utility to break Fortran modules into
individual routines
/usr/bin/include Standard directory for f90 `#include'
files
/usr/bin/ld Link editor (ld)
/usr/include Standard directory for f77 `#include'
files
/usr/include/foriosdef.f PARAMETER statements for IOSTAT values
/usr/include/for_fpe_flags.f PARAMETER statements defining the flags
for floating-point exception handling
used by for_get_fpe( ) and for_set_fpe(
)
/usr/lib/cmplrs/fort/decfort Compaq Fortran 77 compiler
/usr/lib/cmplrs/fort/fort f77 command processor
/usr/lib/cmplrs/fort/for_main.o Fortran "main" program
/usr/lib/cmplrs/fort90/decfort90 f90/f95 Compaq Fortran compiler
/usr/lib/cmplrs/fort90/fort90 f90 command processor
/usr/lib/cmplrs/fort90/fort95 f95 command processor
/usr/lib/cmplrs/fort90/for_main.o Fortran "main" program
/usr/lib/cmplrs/fortrtl/libfor.a
/usr/lib/cmplrs/fortrtl/libfor.so Fortran I/O support
/usr/lib/cmplrs/fortrtl/libFutil.a
/usr/lib/cmplrs/fortrtl/libFutil.so Fortran miscellaneous run-time support
/usr/lib/cmplrs/fortrtl/libUfor.a
/usr/lib/cmplrs/fortrtl/libUfor.so Fortran UNIX interface library, see
intro(3f)
/usr/lib/cmplrs/otabase/libots.a
/usr/lib/cmplrs/otabase/libots.so Fortran run-time string support
/usr/lib/cmplrs/otabase/libots3.a
/usr/lib/cmplrs/otabase/libots3.so f90 parallel processing support
/usr/lib/cord Procedure-rearranger
/usr/lib/cpp C macro preprocessor
/usr/lib/crt0.o Run-time startup
/usr/lib/fpp Fortran macro preprocessor
/usr/lib/ftoc Interface between prof(1) and cord(1)
/usr/lib/libc.a
/usr/shlib/libc.so Standard library, see intro(3)
/usr/lib/libfor.a
/usr/shlib/libfor.so Fortran I/O support
/usr/lib/libFutil.a
/usr/shlib/libFutil.so Fortran miscellaneous run-time support
/usr/lib/libm.a
/usr/shlib/libm.so Math library
/usr/lib/libots.a
/usr/shlib/libots.so Fortran run-time string support
/usr/lib/libphpf.a (parallel)
/usr/shlib/libphpf.so
/usr/lib/libphpfp.a (profiling)
/usr/shlib/libphpfp.so
/usr/lib/libshpf.a (scalar)
/usr/shlib/libshpf.so HPF libraries
/usr/lib/libprof1.a Fortran level 1 profiling library
/usr/lib/libUfor.a
/usr/shlib/libUfor.so Fortran UNIX interface library, see
intro(3f)
/usr/lib/mcrt0.o Fortran startup for profiling
/usr/lib/nls/msg/en_US.88591/for_msg.cat
Fortran run-time message catalog
See Also
as(1), cc(1), cord(1), cpp(1), dbx(1), decladebug(1), fpr(1), fsplit(1),
ftoc(1), gprof(1), ld(1), pixie(1), pprof(1), prof(1), pse(1), what(1),
monitor(3), monstartup(3), read_rnd(3), write_rnd(3), intro(3f)
The Compaq Fortran Language Reference Manual ( formerly the DIGITAL
Fortran Language Reference Manual )
The Compaq Fortran User Manual for Tru64 UNIX and Linux Alpha Systems
( formerly the DIGITAL Fortran User Manual for DIGITAL
UNIX Systems )
The Compaq High Performance Fortran 90 HPF and PSE Manual ( formerly the
DIGITAL High Performance Fortran 90 HPF and PSE Manual )
The Compaq Fortran 77 Release Notes in /usr/lib/cmplrs/fort/relnotes
The Compaq Fortran 90 Release Notes in /usr/lib/cmplrs/fort90/relnotes
The Compaq Fortran 77 help file (text format) in
/usr/lib/cmplrs/fort/decfortran.hlp
The Compaq Fortran 90 help file (text format) in
/usr/lib/cmplrs/fort90/decfortran90.hlp