F90(1)
NAME
f90 - Fortran 90 compiler
SYNOPSIS
f90 [ -ansi ] [ -B[dynamic,static] ] [ -c ] [ -cg89 ]
[ -cg92 ] [ -dalign ] [ -db ] [ -dryrun ] [ -d[y,n] ]
[ -e ] [ -explicitpar ] [ -f ] [ -fast ] [ -fixed ]
[ -flags ] [ -fnonstd ] [ -fnonstop ] [ -fns ]
[ -free ] [ -fround=r ] [ -ftrap=t ] [ -g ] [ -G ]
[ -help ] [ -hnm ] [ -Ipath ] [ -Ldir ]
[ -mt ] [ -Mdir ] [ -native ] [ -nolib ] [ -noqueue ]
[ -norunpath ] [ -o output ] [ -onetrip ] [ -O[n] ]
[ -p ] [ -parallel] [ -pg ] [ -Qoption pr ls ]
[ -reduction ] [ -R path ] [ -s ] [ -stackvar ] [ -S ]
[ -temp=dir ] [ -time ] [ -v ] [ -V ] [ -w ]
[ -xildoff ] [ -xildon ] [ -xlibmopt ]
[ -xlic_lib=libs ] [ -xlicinfo ]
[ -xnolib ] [ -xnolibmopt ] [ -xO[n] ] [ -xpg ]
[ -xpp=p ] [ -xtime ] [ -Xlist ]
source file(s) ... [ -lx ]
DESCRIPTION
f90 is a superset of Fortran 90 (ISO 1539:1991). Version: Sun Fortran 90 1.2 Environment: Solaris 2.3 (SunOS 5.3) or later Purpose: Translate source to an executable (a.out) file
Other Uses:
1. Make an executable for multiple processors, -parallel
2. Do global program checking of source (lint), -Xlist
3. Translate source to relocatable binary (.o) files, -c
4. Translate source to a dynamic library (.so) file, -G
5. Link .o files into an executable file
6. Prepare for debugging, -g
7. Prepare for profiling by statement or procedure, -pg
8. Relink only the changed files, -xildon
The Incremental Link Editor, ild, is sometimes used in place of the standard linker, ld, for faster development. See -xildon and -xildoff for more information.
f77 COMPATIBILITY
Source: Standard FORTRAN 77 is a subset of Fortran 90.
Extensions in Sun f77 are generally not in Sun f90.
I/O: f77 and f90 I/O are generally compatible. See NOTES. libF77: This library is generally compatible with f90.
See -lx and Chapter 7 "Library Functions" in the FORTRAN 77 4.2 Reference Manual or try
man -s 3F intro
FILE SUFFIXES
.f90 File names ending in .f90 are assumed to be Fortran 90 free form source files.
.f File names ending in .f are assumed to be Fortran 90 fixed form source files or standard FORTRAN 77 source files.
.for Same as .f files.
.ftn Same as .f files.
.F90 Free-format Fortran 90 source containing preprocessor directives.
.F Fixed-format Fortran 77 source containing preprocessor directives.
OPTIONS
See ld(1) for link-time options.
-ansi ANSI check. Identify many non-ANSI extensions.
-B[x] Prefer dynamic or require static library linking. Indicates that either dynamic library linking is preferred, or static linking required for any libraries listed later in the command. x must be dynamic or static. The default is dynamic. This is a linker option. −Bdynamic: Prefer dynamic linking (shared libraries)
−Bstatic : Require static linking (no shared libraries) If you specify static but the linker finds only a dynamic library, then the library is not linked and a warning issued. However, if you specify dynamic but the linker finds only a static version, that library is linked with no warning. You can toggle between −Bdynamic and −Bstatic on the command line, linking some libraries statically and others dynamically. These are linker options. Compiling with −Bx requires the same options on a linker command if done in separate steps.
-cg89 Generate code for generic SPARC architecture (SPARC).
This option is a macro for:
−xarch=v7 −xchip=old −xcache=64/32/1
or −xtarget=ss2
−cg92 Generate code for SPARC V8 architecture (SPARC).
This option is a macro for:
−xarch=v8 −xchip=super −xcache=16/32/4:1024/32/1.
or −xtarget=ss1000
−Dname[=def]
Define symbol name for the source code preprocessor. This is equivalent to a “#define” directive in the source. If no def is given, name is defined as “1”. This option applies to .F suffix files only. The following values are predefined on appropriate systems; note the two leading underscores:
__sparc, __unix, __sun, __i386, __SVR4, __SunOS_5_3
They can be in such preprocessor conditionals as
#ifdef __sparc Corresponding older values (prior releases) are:
sparc, unix, sun, i386
These earlier predefined values may be deleted in a future release. f90 uses the fpp(1) preprocessor by default. Like the C preprocessor cpp(1), fpp expands source code macros and enables conditional compilation of code. Unlike cpp, fpp understand Fortran syntax, and is preferred as a Fortran preprocessor. Use the −xpp=cpp flag to force the compiler to specifically use cpp rather than fpp.
−dalign Double align; allow double word load/store. Allow f90 to use double-word load/store. Generate double-word load store instructions wherever possible for faster execution. Using −dalign automatically triggers the −f option, which causes all double-precision and quadruple-precision data types (both real and complex) to be double-word aligned. Using both −dbl and −dalign also causes 64-bit integer data to be double-word aligned. With −dalign, may result in non-ANSI standard FORTRAN alignment; this is a tradeoff of portability for speed. If you compile one subprogram or file with −dalign, then all subprograms and files in the program unit must be compiled with −dalign. −dalign is unsuitable for subprograms that access double-precision data that is not aligned on 8-byte boundaries; unexpected bus errors may occur.
-db Generate a compiler information (CIF) file for f90browse.
-dryrun Show but do not execute commands constructed by the driver.
−d[y|n] Allow/disallow dynamic libraries for executable Allow or disallow dynamic libraries for the entire executable. This is a linker option. The default is −dy. −dy: Allow dynamic libraries.
−dn: Do not allow dynamic libraries. Unlike −B[dynamic|static], this option applies to the whole executable and need appear only once on the command line. −d[y|n] are linker options. If you compile and link in separate steps with these options, then you need the same option in the link step.
-e Extended lines. Extend source line maximum length to 132 characters (for fixed-form source).
−explicitpar
Enable parallelization of loops explicitly marked with directives (SPARC only). This option turns on explicit parallelization. DO loops immediately preceded by DOALL directives will have threaded, parallel code compiled for them. Parallelization is only appropriate on multiprocessor systems. This option should not be used to compile programs that already do their own multithreading with calls to the libthread library. The compiler will generate parallel code even if there are data dependencies in the DO loop that would cause the loop to generate incorrect results when run in parallel. With explicit parallelization, it is the user’s responsibility to correctly analyze loops for data dependency problems before marking them with parallelization directives. If optimization is not at −O3 or higher, then it is raised to −O3. −g cancels −explicitpar. Avoid −explicitpar if you do your own thread management. See −mt. On a single-processor system, the generated code usually runs slower. To improve performance, also specify the −stackvar option when using any of the parallelization options, including −autopar. Risk: See the chapter on Parallelization in the Fortran Programmer’s Guide. If you use −explicitpar and compile and link in one step, then linking automatically includes the microtasking library and the threads-safe FORTRAN runtime library. If you use −explicitpar and compile and link in separate steps, then link with −explicitpar.
−F Invoke the source file preprocessor, but do not compile Apply the fpp preprocessor to .F and .F90 files and put the result in the file with the suffix changed to .for .f90, but do not compile. fpp is the default preprocessor for Fortran. The C preprocessor, cpp, can be selected instead by specifying −xpp=cpp.
−f Align on 8-byte boundaries Align all common blocks and all double-precision and quadruple-precision local data on 8-byte boundaries. This option applies to both real and complex data. Resulting code may not be standard and may not be portable. If you compile one subprogram with −f, compile all subprograms of the program with −f. By itself, this option does not enable the compiler to generate faster double word fetch/store instructions ond double and quad precision data. Only −dalign will do this.
−fast Optimize for speed of execution using a selection of options. Select the combination of options that optimizes for speed of execution without excessive compilation time. This option provides close to the maximum performance for many realistic applications. If you do not specify an optimization level with −fast the default is −O4. This is a convenience option, and it chooses:
o The −native hardware target.
If the program is intended to run on a different target than the compilation machine, follow the −fast with the appropriate −xtarget= option. For example:
f90 −fast −xtarget=ultra ...
o The −O4 optimization level.
o The −libmil option to inline certain math library routines.
o The −dalign option to allow generation of faster double word load/store instructions.
o The −xlibmopt option to link the optimized math library.
o The −fns option for possibly faster handling of underflow.
o The −ftrap=%none option to disable floating-point traps.
Note that this option is a particular selection of other options that is subject to change from one release of the compiler to another, and between compilers. For details on the constituents of −fast, see the Fortran User’s Guide.
Do not use this option with programs that depend on IEEE standard exception handling; you can get different numerical results, premature program termination, or unexpected SIGFPE signals.
For separate compile and link steps: if you compile with −fast, then be sure to link with −fast.
-fixed Source form. Assume fixed-form source. Interpret all Fortran source files according to fixed form rules. This overrides the file suffix.
-flags Synonym for -help.
-fnonstd
Nonstandard arithmetic. This flag is equivalent to -fns -ftrap=common.
The -fnonstd option enables hardware traps for floating-point overflow, division by zero, and invalid operation exceptions. These are converted into SIGFPE signals, and if the program has no SIGFPE handler, it aborts. See ieee_handler(3m), ieee_functions(3m), the Numerical Computations Guide, and SPARC Architecture Manual Version 8.
-fnonstop
No traps on exceptions. Continue on floating-point exceptions. Without -fnonstop, there is a trap on the invalid, overflow, and divide by zero floating-point exceptions.
-fns Use SPARC nonstandard floating point Turn on the SPARC nonstandard floating-point mode. The default is the SPARC standard floating-point mode. On some SPARC processors, this option makes underflow handling faster: underflows always produce zero rather than a possibly subnormal number, as the IEEE standard requires. If you compile one routine with −fns, then compile all the program routines with the −fns option; otherwise, you can get unexpected results.
-free Source form. Assume free-form source. Interpret all Fortran source files according to free-form rules. This overrides the file suffix.
-fround=r
Set IEEE rounding mode Set the IEEE rounding mode in effect at startup. r must be one of:
nearest, tozero, negative, positive. The default is -fround=nearest. This option sets the IEEE 754 rounding mode that:
o Can be used by the compiler in evaluating constant expressions.
o Is established at runtime during the program initialization.
The meanings are the same as those for the ieee_flags subroutine.
If you compile one routine with -fround=r, compile all the program routines with the same -fround=r option; otherwise, you can get unexpected results.
-ftrap=t
Set floating-point trapping This option sets the IEEE floating-point trapping that is in effect at startup. t is a comma-separated list that consists of one or more of the following:
%all, %none, common, [no%]invalid, [no%]overflow, [no%]underflow, [no%]division, [no%]inexact.
The default is -ftrap=common. This option sets the IEEE 754 trapping modes that are established at program initialization. Processing is left-to-right. The common exceptions, by definition, are invalid, division by zero, and overflow. For example:
-ftrap=overflow. Example: Set all traps, except inexact.
-ftrap=%all,no%inexact
The meanings are the same as for the ieee_flags function, except that:
o %all turns on all the trapping modes.
o %none, the default, turns off all trapping modes.
o A no% prefix turns off that specific trapping mode.
If you compile one routine with -ftrap=t, compile all routines of the program with the same -ftrap=t option; otherwise, you can get unexpected results.
-g Debugger. Produce additional symbol table information for dbx(1) or debugger(1). -g overrides -O. The -O is turned off. -g cancels any of the parallelization options
( -explicitpar or -parallel). The -g option makes -xildon the default incremental linker option (see -xildon). That is, with -g, the compiler default behavior is to automatically invoke ild in place of ld, unless the -G option is present, or any source file is named on the command line.
-G Dynamic library. Build a dynamic library. -G is a linker option. It tells the linker to make a dynamic library. Without -G the linker builds an executable file. -G turns off the Incremental Linker (see -xildon).
-h nm Dynamic library name. Make nm the name of the dynamic library generated. If the library has an internal name, then whenever the executable is run, the linker must find a library with the same internal name; the file can be in any library search path. If the library has no internal name, then the linker must find a library with the same path as when it was generated. So having an internal name allows more flexibility at runtime. Remarks
The space between the -h and nm is optional.
-hnm is meaningless without -G.
-hnm is a linker option.
The names after -h and -o are usually the same.
-hnm facilitates versions for dynamic libraries.
See the Linker and Libraries Manual.
-help Options. Display the list of options. Display an equivalent of this list of options and show how to send feedback comments to Sun.
-Ipath Include path. Insert path at the beginning of the list of directories which are to be searched for INCLUDE files.
Search order for the INCLUDE files:
1. The directory containing the source file
2. Directories named in -I options
The path in the -Ipath option is for INCLUDE files with relative path names, not absolute path names.
-lx Library. Link with library libx.a. Direct the loader to link with object library libx.a, where x is a string. See ld(1). Example: -lF77 links in the library libF77.a -lx and Order on the Command Line: Place -lx options after any .f or .o files. If you call functions in libx, and they reference functions in liby, then place -lx before -ly. -lx and Search Order for -lx files. The linker searches for libraries in several locations. For details, see the chapter Libraries in the Fortran Programmer’s Guide
−Ldir Add dir to list of directories to search for libraries. dir is added to the start of the search list. A space between −L and dir is optional. Risk: Do not use the −Ldir option to specify /usr/lib or /usr/ccs/lib, since they are searched by default, and including them here prevents using the unbundled libm.
-mt Multithread libraries. Use multithread safe libraries. If you are doing your own multithread coding (not using the -explicitpar or -parallel, options) then you must use the -mt option in the compile and link steps. The parallelization options use -mt automatically. The -mt option requires a WorkShop license. On a single-processor system the generated code usually runs slower with this option.
-Mdir Module directory. Look for modules in dir. Look for Fortran 90 modules in the dir directory, in addition to the current working directory. By default, such files are sought in the current working directory. The -Mdir option allows you to keep them in some other location. No space is allowed between -M and dir. If a file containing a Fortran 90 module is compiled, f90 generates a module file, .M file, in addition to the .o file.
-native −native Optimize for the host system. The −native option is a synonym for the −xtarget=native option.
-nolib No automatic system library. Do not automatically link with any system or language library. Do not pass any -lx options on to ld. The default is to link such libraries into the executables automatically, without the user specifying them on the command line. The system and language libraries are required for final execution. It is the users responsibility to link them in manually. This provides complete control (and with control comes responsibility) for the user. The -nolib option makes it easier to link one of these libraries statically. For example, an application linked dynamically with libf90 fails on a machine that has no libf90. You can avoid such failure by shipping libf90 to your customer, or by linking it statically. Example: Link libm statically, libc dynamically.
f90 -nolib any.f90 -lf90 -Bstatic -lm -Bdynamic -lc
There is no dynamic libf90; it is always linked statically. Order for -lx options is important. Use the order shown in the example.
-noqueue
No license queue. Do not queue the request for a license. If you use this option and no license is available, the compiler returns without queuing your request and without doing your compile. A nonzero status is returned for testing in make files.
-norunpath
No run path in executable. Do not store library path in executable. If an executable file uses shared libraries, then the compiler normally builds in a path that tells the runtime linker where to find those shared libraries. The path depends on the directory where you installed the compiler. The -norunpath option prevents that path from being built in to the executable. This option is helpful if you have installed in some nonstandard location, and you ship an executable file to your customers, but you do not want to make the customers deal with that nonstandard location.
-o nm Name of output file. Name the final output file nm instead of a.out. The space is required between -o and nm.
-onetrip
One-trip DO loops. Perform DO loops at least once if reached. Compile DO loops so they are performed at least once if reached. f90 Fortran DO loops are not performed at all if the upper limit is smaller than the lower limit, unlike some FORTRAN 66 implementations of DO loops.
-O[n] Optimization. Optimize object code for speed. The n can be 1, 2, 3, or 4. No space is allowed between -O and n. The -g option suppresses -O[n]
Note: If -O[n] is not specified, the compiler does no scalar optimization. It still performs a default level of optimization; that is, it executes a single iteration of local common subexpression elimination and live/dead analysis.
-O Optimize at the level most likely to give close to the maximum performance for most realistic applications (currently -O3).
-O1 Do only conservative scalar optimization. This level usually results in moderate code size and compile time. If an optimization can create a false exception, then that optimization is not performed. At this level, f90 cannot analyze whether a variable is used before it is defined.
-O2 Do moderate optimization.
-O3 Do aggressive scalar optimization. Some of these optimizations can create false exceptions. This level can result in larger code size and compile time. At this level, f90 can analyze whether a variable is used before it is defined.
-O4 For this release, -O4 is equivalent to -O3.
-p Profiles. Profile by procedure for prof. Prepare object files for profiling with prof. This makes profiles by procedure, showing the number of calls to each procedure and the percent of time used by each procedure. For separate compile and link steps, if you compile with -p, then link with -p.
-parallel
Parallelization. Parallelize automatically and parallelize explicitly indicated loops. Find and parallelize appropriate loops automatically and parallelize loops explicitly specified by the user. Example: f90 -parallel any.f90 -g turns off -parallel. Avoid -parallel if you do your own thread management. See -mt. Do not mix parallelized f77 and parallelized f90. With any parallelization option, if optimization is less than -O3, it is set to -O3. The -parallel option requires a WorkShop license. To get faster code, use this option on a multiprocessor SPARC system. On a single-processor system the generated code usually runs slower. Use of -stackvar with -parallel is recommended for performance. If you compile and link in separate steps, and you compile with -parallel, then link with -parallel. Number of processors: To request more than one processor, set the PARALLEL environment variable. If N is the number of processors available, then for a one-user, multiprocessor system, try PARALLEL=N-1. Risk: Requesting more processors than are available on the machinee can cause serious degradation of performance.
-pg Profiles. Profile by procedure for gprof. Prepare the object files for profiling with gprof. This makes profiles by procedure, showing the number of calls to each procedure and the percent of time used by each procedure. This produces counting code in the manner of -p, but invokes a runtime recording mechanism that keeps more extensive statistics and produces a gmon.out file at normal termination. You can then generate an execution profile using gprof(1). For separate compile and link steps, if you compile with -pg, then link with -pg.
-Qoption pr ls
Option passing. Pass option list ls to the program pr. The list is a comma-separated list of options, no blanks within the list. Each option must be appropriate to pr and may begin with a minus sign. The assembler used by the compiler is fbe. Example: Load map. f90 -Qoption ld -m any.f90
Example: ld help. f90 -Qoption ld -Dhelp any.f90
-reduction
Reduction loops. Analyze loops for reduction while parallelizing. To enable parallelization of reduction loops, specify -reduction and -parallel. If you specify -reduction without -parallel, the compiler issues a warning. This option requires a Sun Performance WorkShop License. On a single-processor system the generated code usually runs slower. Example: f77 -parallel -reduction any.f90 There is always potential for roundoff error with reduction. Use: If you have a reduction loop to be parallelized, then use -reduction (with -parallel, of course).
-R ls Library paths. Store library paths paths in a.out. Store a list of library search paths into the output object file and pass the list to the runtime linker, ld(1). ls is a colon-separated list of directories used to specify library search paths to the runtime linker. The blank between -R and ls is optional. If both LD_RUN_PATH and the -R option are specified, the libraries in the -R list are stored and those in LD_RUN_PATH are ignored.
Multiple instances of this option are concatenated together with each list being separated by a colon.
Use: Use this if you want to ship an executable that your users can run without any special option for paths to your dynamic libraries.
-s Symbol table off. Strip the executable file of its symbol table (makes debugging impossible).
-stackvar
Local variables on stack. Allocate local variables on the stack. Use the stack to allocate all local variables in a subprogram unless otherwise specified. This is equivalent to declaring them to be automatic. Parallel CALL: The -stackvar option gives more freedom to the optimizer for such tasks as parallelizing a loop that includes a CALL.
Segmentation fault and -stackvar: you can get a segmentation fault using -stackvar with large arrays. putting large arrays on the stack can overflow the stack, so you may need to increase stack size. See User’s Guide, under -stackvar, or see csh (1) for details on the limit command.
-S Assembly source. Generate assembly source files. Compile the named files and leave the assembly language output on corresponding files suffixed .s (no .o file is created).
-temp=dir
Temporary files. Put temporary files into dir. Set directory for temporary files used by f90 to be dir instead of the /tmp/ directory.
-time Execution times. Report execution times for the various compilation passes.
-v Verbose. Print the name of each pass as the compiler executes, also display in detail options and environment variables used by the driver.
-V Version ID. Print the name and version ID of each pass as the compiler executes.
-w[n] Warnings off. Suppress warning messages. The n can be any one of 0, 1, 2, 3, or 4.
-w0 suppresses the most warnings.
-w4 suppresses the least warnings.
-w with no n is the same as -w0.
-xildoff Turn off Incremental Linker
This forces the use of the standard linker, ld. This option is the default if you do not use -g. It is also the default if you use -G or name any source file on the command line. Override this default by using -xildon.
-xildon Turn on Incremental Linker
Turn on the Incremental Linker and force the use of ild in incremental mode. This option is the default if you use -g, and do not use -G, and do not name any source file on the command line. Override this default by using -xildoff.
-xlibmopt
Fast math library. Use a library of fast math routines. Use a library of selected math routines optimized for performance. This usually generates faster code. It may produce slightly different results; if so, they usually differ in the last bit. The order on the command line for this library option is not significant.
−xlic_lib=libs
Link with specified Sun licensed libraries. Example: linking with the Sun Performance Library:
f90 -o pgx -fast -xlic_lib=sunperf pgx.f
-xlicinfo
License information. Return license information. Return information about the licensing system. In particular, return the name of the license server and the user IDs of users who have licenses checked out. Generally, with this option no compilation is done and a license is not checked out. If a conflicting option is used, then the latest one on the command line wins and there is a warning.
Example: f90 -c -xlicinfo any.f90
Does not compile; does report license information.
Example: f90 -xlicinfo -c any.f90
Does compile; does not report license information.
-xnolib Synonym for -nolib.
-xnolibmopt
Fast math library off. Reset -fast to not use special fast routines. Reset -fast so that it does not use the library of selected math routines optimized for performance. Use this after the -fast option:
f90 -fast -xnolibmopt ...
-xO[n] Synonym for -O[n].
-xpg Synonym for -pg.
−xpp=p
Select source file preprocessor. p is either fpp or cpp. Selects the source file preprocessor to be used with .F90 files. The default is fpp, which is appropriate for Fortran 90. Previous versions of the compiler used cpp, the standard C language preprocessor. To select cpp, specify -xpp=cpp.
-xtime Synonym for -time.
-Xlist Global program checking. Check across routines. Check for consistency. This helps find a variety of bugs. In general, -Xlist also makes a line-numbered listing of the source and a cross reference table of the identifiers. The errors found do not prevent the program from being compiled and linked. Output is to a file with a name like the first file name but with a .lst extension. Example: f90 -Xlist nam1.f90 nam2.f90 nam3.f90
The above example puts errors, listing, and cross-reference table onto file nam1.lst. Summary of -Xlist Suboptions
-Xlist Default: listings, errors, xref
-XlistE Errors only (no xref or listings)
-Xlisterr Suppress all -Xlist error messages
-Xlisterr[n] Suppress -Xlist error message n
-XlistI Check include files also
-XlistL Listings only (no xref)
-Xlistl[n] Page length is n lines
-Xlistonm Output to nm instead of to file.lst
-Xlistwar Suppress all -Xlist warning messages
-Xlistwar[n] Suppress -Xlist warning message n
-XlistX Xref only (no listings)
Other arguments are taken to be either linker option arguments, or names of f90-compatible object programs, typically produced by an earlier run, or libraries of routines that are f90-compatible. These programs, together with the results of any compilations specified, are linked (in the order given) to produce an executable program in the file specified by the -o option, or in a file named a.out if the -o option is not specified.
DIRECTIVES
f90 allows compiler directive lines starting with CDIR$, !DIR$, CMIC$, or !MIC$. The form starting with "!" works for both free-form and fixed-form source.
!DIR$ FIXED Interpret the rest of the source file as Fortran 90 fixed form.
!DIR$ FREE Interpret the rest of the source file as Fortran 90 free form. If either a FREE or FIXED directive is used, that overrides the option and file name suffix.
!MIC$ DOALL The DOALL directive tells the compiler to parallelize the next loop it finds, if possible. There are risks. See -parallel and -explicitpar.
ENVIRONMENT
PATH
To use f90, add the following to the start of the search path: Standard Install: /opt/SUNWspro/bin/
Nonstandard Install to /my/dir: /my/dir/SUNWspro/bin/
MANPATH
To access the f90 man pages, add the following to the MANPATH environment variable:
Standard Install: /opt/SUNWspro/man/
Nonstandard Install to /my/dir: /my/dir/SUNWspro/man/
LD_LIBRARY_PATH
Generally, you need not set up LD_LIBRARY_PATH. If you do need to do so, then maybe there is some discrepancy in the installation, or some executable has been built incorrectly. Set the LD_LIBRARY_PATH environment variable to: Standard Install: /opt/SUNWspro/lib/
Nonstandard Install to /my/dir/: /my/dir/SUNWspro/lib
LD_RUN_PATH
If you use LD_RUN_PATH, note that for f90, LD_RUN_PATH is not identical with -R. (For ld.so, they are identical.) See -R, in the Fortran User’s Guide, for details.
FILES
Selected major files used by the compiler
a.out Executable output file
file.a Library of object files
file.f Fixed-form Fortran 90 or standard FORTRAN 77 source file
file.f90 Free-form Fortran 90 source file
file.for Same as .f
file.ftn Same as .f
file.M Module information file
file.o Object file
file.T CIF file, for global program checking
file.s Assembler source file
mon.out File produced for analysis by prof(1)
gmon.out File produced for analysis by gprof(1)
/usr/lib/libc.a Standard C library, see intro(3)
/usr/lib/libp/libc.a Profiling library, see intro(3)
/tmp/∗ Compiler temporary files
/usr/lib/libm.a Math lib (2.x)
/usr/lib/libp/libm.a Math profile lib (2.x)
The remaining files are in the following directory (the ‘4.2’ varies with the release of the compilers.): Standard Install: /opt/SUNWspro/SC4.2/
Nonstandard Install to /my/dir/: /my/dir/SUNWspro/SC4.2/
bin/f90 Compiler command-line processing driver
bin/f90list Global program checker
bin/f90comp Parser
lib/libf90.a f90 lib, includes I/O & UNIX interface
lib/libsunmath.a Sun Value-added math lib
READMEs
The READMEs directory contains information files: bug descriptions, information discovered after the manuals were printed, a customer feedback form, and so forth. Location of READMEs directory:
Standard Install: /opt/SUNWspro/READMEs/
Nonstandard Install to /my/dir/: /my/dir/SUNWspro/READMEs/ Files in READMEs/:
o feedback
o fortran_90
SEE ALSO
asa(1), cc(1), dbx(1), fpr(1), fsplit(1), gprof(1), ild(1), ld(1), perror(3f), prof(1).
Fortran User’s Guide
Fortran Programmer’s Guide
Fortran 90 Handbook
Fortran 90 Browser
Numerical Computation Guide
Profiling Tools
Linker and Libraries Manual
WorkShop Installation and Licensing Guide See the performance_library information file and the libsunperf Reference Manual PostScript files in the READMEs/ directory. This library is part of the optional High Performance Workshop. This library contains subroutines and functions to perform useful operations in computational linear algebra and Fourier transforms.
LICENSING
Before you run f90, a license must be installed. Licensing information is included in the manual WorkShop Installation and Licensing Guide, including:
o Installing a license
o Starting a license daemon
o Restarting a license daemon (after license server crash)
NOTES
I/O Compatibility
Fortran 90 and FORTRAN 77 use different I/O libraries. However, this should be transparent to the user. That is, programs can do I/O to the same unit from both the Fortran 90 and FORTRAN 77 parts of the code. Caveat: I/O compatibility requires that Fortran 90 1.1 programs be linked with programs compiled with FORTRAN 77 4.0. That is, Fortran 90 1.1 I/O is not compatible with FORTRAN 77 3.0.1 or earlier. Do the numbers read equal the numbers written?
Unformatted: Numbers read do equal numbers written. Floating-point formatted: The numbers read can be different from the numbers written. This is caused by slightly different base conversion routines, or by different conventions for uppercase/lowercase, spaces, plus or minus signs, and so forth.
Examples: 1.0e12, 1.0E12, 1.0E+12 List-directed: The numbers read can be different from the numbers written. This can be caused by various layout conventions with commas, spaces, zeros, and so forth.
Example: 0.0 as compared to .0
Example: ’ 7’ as compared to ’7’
Example: ’3, 4, 5’ as compared to ’3 4 5’
Example: 1.0/3.0 in single and double precision
f77 0.333333 0.33333333333333
f90 0.333333343, 0.33333333333333331
Example: Complex numbers
f77 ( 1.00000, 0.333333)
f90 (1.,0.333333343)
Example: Arrays--DATA a /3.0, 9∗0.0/
f77 3.0 0. 0. 0. 0. 0. 0. 0. 0. 0.
f90 3.0 9∗0.E+0
MP Parallelization is generally compatible between intermixed f77 and f90 compiled code.
Debugger
Debugging requires the new debugger. If you try to use the SW3.0.1 debugger on Fortran 90 code, then the debugger may not recognize some f90 features.
f90 This product is derived from Cray CF90(tm), a product of Cray Research, Inc.
DIAGNOSTICS
The diagnostics produced by f90 itself are intended to be self-explanatory. Occasional messages may be produced by the linker.
— Last change: 15 November 1996 1.2