THE FORTRAN IV-PLUS COMPILER The FORTRAN IV-PLUS compiler is an optimizing Fortran compiler capable of producing in-line code. It can potentially produce a Fortran program which executes almost as fast as an assembly language program. By convention /SW sets the switch action and /NOSW (or /-SW) negates the switch action ( /SW represents a switch). The command line to the compiler looks like: F4P> object-file, list-file/listswitch = source-file/switches The default extensions are .FTN for the source-file(s), and .OBJ for the object-file. Further HELP may be obtained by typing HELP F4P KEYWORD, using one of the following keywords. ERROR (Options for getting HELP on errors) ERROR Rnn (HELP for a specific Runtime error number) ERROR Cnn (HELP for a specific Compile error number) SWITCHES (Summary of F4P compiler switches) LIST (Listing Switch Summary) BUILD (Help for Fortran Compile Link and Go) 2 ERROR @F4PERROR.HLP 2 LIST F4P Listing Options /LI:n Specifies listing options, 0<=n<=3. (Defaults to LI:2) n=0 Minimal listing file. Diagnostic messages and program section summary only. n=1 Source listing and program section summary. n=2 Source listing, program section summary, and storage map n=3 Source listing, assembly code, program section summary, and storage map. 2 SWITCHES F4P Compiler Switch Options /CK check array references /CO:n specify # continuation lines /DE compile debug lines /ID print compiler version number /I4 allocate 2 words/integer /LA latch switch setting for subsequent compilations /LI:n list switch /RO generate read only code /SP spool listing file /TR:xxx controls error traceback /WF:n specify number of work files /WR enable warning diagnostics Switch default summary: /NOCK/CO:5/NODE/NOI4/NOLA/LI:2/NORO/NOSP/TR:BLOCKS/WF:2/WR HELP on any of these switches may be obtained by typing HELP F4P SWITCH /sw. where sw is the desired switch. 3 CK /CK Code is generated to check that all array references are within array address bounds. The default is /NOCK. Use of this switch makes the task size larger and execution times slower, but it is useful for debugging. 3 CO /CO:n A maximum of n continuation lines are permitted in the program, 0<=n<=99. The default value is 5. The number n is expressed as a decimal number if followed by a period, else it is interpreted as an octal number. 3 DE /DE Compile lines with a D in column 1. These lines are treated as comment lines by the default /NODE switch. 3 ID /ID Prints out the compiler version number. The default is /NOID. 3 I4 /I4 Allocate two words for default length integer and logical variables. /NOI4 is the default. 3 LA /LA Causes the current switch settings to be retained (latched) for subsequent compilations. Default is /NOLA. 3 LIST /LI:n Specifies listing options, 0<=n<=3.(Default is /LI:2) See HELP F4P LIST. 3 RO /RO Directs the compiler to specify pure code and pure data sections as READ ONLY(RO). The default is /NORO. 3 SP /SP Automatically spool listing file. The default is /NOSP. 3 TR /TR:XXX The /TR switch controles the amount of extra code included in the compiled output for use in error traceback. The default is /TR:BLOCKS. /TR /TR:ALL /TR:LINES Error traceback is compiled for all source statements and function and subroutine entries. /TR:BLOCKS Traceback information is compiled for subroutine and function entries and for certain selected source statements (starting off a block). /TR:NAMES Traceback information is compiled only for subroutine and function entries. /TR:NONE /NOTR Disables all traceback (and produces shorter, faster executing programs). 3 WF /WF:n The /WF switch determines the number of temporary external workfiles used to compile the program. One, two, or three files can be used. One file produces the shortest compilation time, but can compile only small (short) programs. Three files can compile three times as many statements as one file, but but requires three times more time per statement than one single file compilations. The default is /WF:2. 3 WR /WR Enable compiler warning diagnostics (w-class messages). The default is /WR. 2 BUILD Compile-Link-and-Go FORTRAN To simplify the compiling and building of FORTRAN programs by the general user a CCL command is provided which any user may use to compile, build, and run FORTRAN programs. To automatically compile, build, and run a program type FCLG filename list-file library-file This command will build a runnable task image from a FORTRAN source file. However, certain assumptions about defaults are imposed on the user: >>> 1. The TYPE of the source file must be FTN. ONLY TYPE IN THE PROGRAM >>> NAME---YOU MUST OMIT TYPING IN THE PROGRAM TYPE AND VERSION. (E.g., type FCLG MYPROG , NOT FCLG MYPROG.FTN !!) 2. The FORTRAN compiler's switches are all set for the default values. 3. A task may have only 4 active files at a time. 4. A task may have only 6 logical units. 5. The logical unit numbers assigned to devices default to: ASG = SY:1:2:3:4,TI:5:CL:6 6. The .OBJ file belonging to the taskname is deleted after Task Building.