© Digital Equipment Corporation 1997. All rights reserved. 15-Sep-1997 1.0 DIGITAL Fortran v5.0 for DIGITAL UNIX Alpha Systems These are the release notes for Version v5.0 of DIGITAL Fortran for DIGITAL UNIX Alpha Systems. It contains bug fixes, some new features, and performance enhancements to the current versions of DIGITAL Fortran for Alpha/UNIX. These release notes describe changes made to the FORTRAN-77 based compiler (DFAO) and the common DIGITAL Fortran RTL since the DIGITAL Fortran V4.1 release. Previous version of these release notes for V4.1 ECO 01, V4.1, V4.0 and V3.8 are appended. After installation, these release notes can be found in /usr/lib/cmplrs/fort/relnotes After installation, the release notes for the Fortran-90 based compiler can be found in /usr/lib/cmplrs/fort90/relnotes DFAO v5.0 will run on DIGITAL UNIX v4.0 or later systems. 1.1 Installation The DFAO v5.0 native software is a setld kit. It contains the following subsets: DFABASE500 DIGITAL Fortran 90 and 77 v5.0 for DIGITAL UNIX Alpha Systems DFADOC500 DIGITAL Fortran v5.0 Release Notes and Man Pages DFACOM500 DIGITAL Fortran v5.0 Tools and their Man pages DFARTL373 DIGITAL Fortran RTL #373 for DIGITAL UNIX Alpha (f77 only) DFARTL376 DIGITAL Fortran Runtime Support for DIGITAL UNIX Systems (f90 and f77) PSESHPF107 High Performance Fortran Run-Time Scalar (nonparallel) Library OTABASE200 DIGITAL Compiled Code Support Library #200 Note that DFARTL373 can be used with f77 only. DFARTL376 is used with both f90 and f77. ++++ Important Note about Installing DFARTLnnn ++++ ++++ ++++ ++++ If you tell setld to install both DFARTL373 ++++ ++++ and DFARTL376, they will install in no pre- ++++ ++++ determined order and one will overwrite the ++++ ++++ links to the other's files. Both will be ++++ ++++ listed as INSTALLED. If you now delete one, ++++ ++++ you will delete the links to the DF RTL library ++++ ++++ files and you will not be able to execute DF ++++ ++++ programs. ++++ ++++ ++++ ++++ Install only one of either DFARTL373 {for f77 ++++ ++++ use only} or DFARTL376 {for use with both f90 ++++ ++++ and f77}. ++++ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ For a detailed description of the installation procedure, see the DIGITAL Fortran Installation Guide for DIGITAL UNIX Systems. You may also send comments, questions and suggestions about the DIGITAL Fortran products to the following mail address: fortran@digital.com Please note that this address is for informational inquiries and is not a formal support channel. If you have Internet access and a World Wide Web (WWW) viewer, you are welcome to view the following: * The DIGITAL Fortran home page, located at the following URL: http://www.digital.com/fortran * The DIGITAL Equipment Corporation home page, located at the following URL: http://www.digital.com Note that the libraries {libots} in the OTABASE subset are no longer on the DFAO kit since those libraries ship with AOSF v3.0 and later. The what string in libots.a should be "T1.3-008G GEM 9 Feb 1994" or newer. If you are using DIGITAL UNIX Version 4.0, be aware of the following changes to the OSFCMPLRS operating system subset: Beginning with DIGITAL UNIX Version 4.0, the OSFCMPLRS subset now consists of multiple subsets: OSFCMPLRS (required for program development), OSFSDE (profiling tools), OSFLIBA (archive libraries), OSFINCLUDE (include files), OSFATOM (atom tools) 1.2 DFAO Files The following files and their what(1) strings are included in the v5.0 release: decfort DIGITAL Fortran 77 V5.0-138 -3678F fort DIGITAL Fortran 77 Driver V5.0-7 fortpr DIGITAL Fortran Printer Driver V5.0-3 fsplit DIGITAL Fortran 77 File Splitter V5.0-7 fpp DIGITAL Fortran Preprocessor V1.0-1 decfort90 DIGITAL Fortran 90 Compiler V5.0-492 -3678F DFARTL376 contains libFutil.a Digital Convert RTL V1.1-73 1+ 6-may-1997 libUfor.a Digital Fortran Unsupported RTL V1.1-25 1+ 30-sep-1996 libfor.a Digital Fortran RTL V1.1-453 1+ 10-jul-1997 libFutil.so Digital Convert RTL V1.1-73 1+ 6-may-1997 libUfor.so Digital Fortran Unsupported RTL V1.1-25 1+ 30-sep-1996 libfor.so Digital Fortran RTL V1.1-453 1+ 10-jul-1997 for_msg.cat Digital Fortran RTL Message Catalog V1.1-15 18-Jun-1997 for_main.o Digital Fortran "main" program V1.0 DFARTL373 contains libFutil.a DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.a DEC Fortran Unsupported RTL V1.1-23 1+ 5-apr-1996 libfor.a DEC Fortran RTL V1.1-346 1+ 12-jun-1996 libFutil.so DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.so DEC Fortran Unsupported RTL V1.1-23 1+ 5-apr-1996 libfor.so DEC Fortran RTL V1.1-346 1+ 12-jun-1996 for_msg.cat DEC Fortran RTL Message Catalog V1.1-11 29-Mar-1996 for_main.o DEC Fortran "main" program V1.0 The listing file version string in the page header is "DIGITAL Fortran 77 V5.0-138" OTABASE200 contains libots3.a V0.0-009 GEM 18 Jul 1997 libots3.so V0.0-009 GEM 18 Jul 1997 1.3 What Has Changed in DFAO V5.0 from DFAO V4.1 ECO o The following changes were made to the decfort compiler from edit -134 through -138: - Allow pointees to be used in ASF and VFE contexts. - "-check bounds" code will be removed by the optimizer if the code to access the object being checked is not accessed. o The following changes were made to the f77 driver: - None. o The following changes were made to the run-time support: Here are the changes made in the RTL since #375. Customers may ignore the DEC-internal tracking information following the description. DFARTL376 Changes between 23-May-1997 and 10-Jul-1997 in -437 to -453: - Access violation with read past end of internal file - (DFB 2632) - added support for cpu_time intrinsic - RANDOM_SEED with no arguments uses clock based random seeds - a bug involving an I/O list with multiple list items and a foreign file was fixed - dfb2639 - fortran note 1354 - ONLY IN F77 compiler o The following changes to DFAO documentation should be noted: - None. o Please note the following: - The current release of KAP Fortran 77 for UNIX (v3.1a) does a check at installation time to make sure that you have Fortran v4.* installed. The KAP installation will fail if you try to install KAP on a system with DIGITAL Fortran v5.0 because the KAP installation script is looking for Fortran v4.*. To get around this, you need to edit the installation script, KPFBASE311.scp, and change the line: STL_DepEval DFABASE4?? || { to the line: STL_DepEval DFABASE??? || { The next release of KAP Fortran 77 for UNIX will install and work correctly with DIGITAL Fortran v5.0. - When using the -S command line option to build an assemblable .s file, the compiler turns all local variables into names that start with $$. This is done is to ensure that local variables do not conflict with any global variables in the application. There is no concept of "local" vs "global" symbols in .s files. - The X-Open Standard followed by DIGITAL UNIX made a change to its "pow" function that affects Fortran's "**" operation: (0.0)**Y for all negative values of Y {single or DOUBLE PRECISION} will now return "-Infinity" {using -fpe3}; it used to return "+Infinity". - The UNIX linker will give an error error: /sbin/loader: fatal error set program attributes failed to set heap-start. when there isn't enough room to map the program. The message will be changed to Program exceeds datasize limit in a future release of UNIX. The fix is to increase the datasize limit with the C shell command limit datasize unlimited - Touching uninitialized pointers can cause program failure. The uswitch(2) function call changes the semantics of these accesses: When the USW_NULLP bit of uswitch is set to 1, the System V method of treating NULL pointers is applied. In this method, references to a NULL pointer always returns zero (0). When this bit-mask is reset to zero (0), subsequent references to a NULL pointer generate a segmentation violation signal (SIGSEGV). - Please read the "Please note the following" sections in the attached release notes. - You only need to install one of DFARTL373 or DFARTL376: see the "Important Note about Installing DFARTLnnn" above. ******************************************************************************** © Digital Equipment Corporation 1997. All rights reserved. 31-May-1997 0.0 DIGITAL Fortran V4.1 ECO for DIGITAL UNIX Alpha Systems These are the release notes for the first ECO revision of Version 4.1 of DIGITAL Fortran for DIGITAL UNIX Alpha Systems. Version 4.1 ECO is a maintenance release that contains corrections to problems discovered since Version 4.1 was released. These release notes describe changes made to the FORTRAN-77 based compiler (DFAO) and the common DIGITAL Fortran RTL since the DIGITAL Fortran V4.1 release. Previous version of these release notes for V4.1, V4.0 and V3.8 are appended. After installation, these release notes can be found in /usr/lib/cmplrs/fort/relnotes After installation, the release notes for the Fortran-90 based compiler can be found in /usr/lib/cmplrs/fort90/relnotes DFAO V4.1 ECO will run on DIGITAL UNIX v3.x, v4.0, or later systems. 0.1 Installation The DFAO V4.1 ECO native software is a setld kit. It contains the following subsets: DFABASE411 DIGITAL Fortran 90 and 77 V4.1 (u1) for DIGITAL UNIX Alpha Systems DFADOC410 DIGITAL Fortran V4.1 (u1) Release Notes and Man Pages DFACOM410 DIGITAL Fortran V4.1 (u1) Tools and their Man pages DFARTL373 DIGITAL Fortran RTL #373 for DIGITAL UNIX Alpha (f77 only) DFARTL375 DIGITAL Fortran Runtime Support for DIGITAL UNIX Systems (f90 and f77) PSESHPF107 High Performance Fortran Run-Time Scalar (nonparallel) Library Note that DFARTL373 can be used with f77 only. DFARTL375 is used with both f90 and f77. ++++ Important Note about Installing DFARTLnnn ++++ ++++ ++++ ++++ If you tell setld to install both DFARTL373 ++++ ++++ and DFARTL375, they will install in no pre- ++++ ++++ determined order and one will overwrite the ++++ ++++ links to the other's files. Both will be ++++ ++++ listed as INSTALLED. If you now delete one, ++++ ++++ you will delete the links to the DF RTL library ++++ ++++ files and you will not be able to execute DF ++++ ++++ programs. ++++ ++++ ++++ ++++ Install only one of either DFARTL373 {for f77 ++++ ++++ use only} or DFARTL375 {for use with both f90 ++++ ++++ and f77}. ++++ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ For a detailed description of the installation procedure, see the DIGITAL Fortran Installation Guide for DIGITAL UNIX Systems. You may also send comments, questions and suggestions about the DIGITAL Fortran products to the following mail address: fortran@digital.com Please note that this address is for informational inquiries and is not a formal support channel. If you have Internet access and a World Wide Web (WWW) viewer, you are welcome to view the following: * The DIGITAL Fortran home page, located at the following URL: http://www.digital.com/fortran * The DIGITAL Equipment Corporation home page, located at the following URL: http://www.digital.com Note that the libraries {libots} in the OTABASE subset are no longer on the DFAO kit since those libraries ship with AOSF v3.0 and later. The what string in libots.a should be "T1.3-008G GEM 9 Feb 1994" or newer. If you are using DIGITAL UNIX Version 4.0, be aware of the following changes to the OSFCMPLRS operating system subset: Beginning with DIGITAL UNIX Version 4.0, the OSFCMPLRS subset now consists of multiple subsets: OSFCMPLRS (required for program development), OSFSDE (profiling tools), OSFLIBA (archive libraries), OSFINCLUDE (include files), OSFATOM (atom tools) 0.2 DFAO Files The following files and their what(1) strings are included in V4.1 ECO: decfort Digital Fortran 77 X4.1-134 -335G fort Digital Fortran Compiler Driver X4.1-6 fortpr Digital Fortran Printer Driver X4.1-2 fsplit Digital Fortran Splitter X4.1-2 fpp Digital Fortran Preprocessor V1.0-1 DFARTL375 contains libFutil.a Digital Convert RTL V1.1-73 1+ 6-may-1997 libUfor.a Digital Fortran Unsupported RTL V1.1-25 1+ 30-sep-1996 libfor.a Digital Fortran RTL V1.1-436 1+ 20-may-1997 libFutil.so Digital Convert RTL V1.1-73 1+ 6-may-1997 libUfor.so Digital Fortran Unsupported RTL V1.1-25 1+ 30-sep-1996 libfor.so Digital Fortran RTL V1.1-436 1+ 20-may-1997 for_msg.cat Digital Fortran RTL Message Catalog V1.1-14 07-Jan-1997 for_main.o Digital Fortran "main" program V1.0 DFARTL373 contains libFutil.a DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.a DEC Fortran Unsupported RTL V1.1-23 1+ 5-apr-1996 libfor.a DEC Fortran RTL V1.1-346 1+ 12-jun-1996 libFutil.so DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.so DEC Fortran Unsupported RTL V1.1-23 1+ 5-apr-1996 libfor.so DEC Fortran RTL V1.1-346 1+ 12-jun-1996 for_msg.cat DEC Fortran RTL Message Catalog V1.1-11 29-Mar-1996 for_main.o DEC Fortran "main" program V1.0 The listing file version string in the page header is "DIGITAL Fortran 77 X4.1-134" 1.3 What Has Changed in DFAO V4.1 ECO from DFAO V4.1 o The following changes were made to the decfort compiler from edit -93 through -134: - Deferred function argument expression can cause problems. Example is: if(f(i,(.not.x).and.y))then. - Allow main program to generate .s file (force MAIN__ symbol out). - Be more tolerant of large untyped things like SIZEOF(X'FFFFFFFFFFFFFFFFFFF'). - Do not delete adjustable arrays that are EQUIVALENCEd into COMMON. - Allow CHARACTER C*10(20) syntax in addition to C(20)*10. - Fix for large (integer*8 sized) constant subscripts. - Fix f90 automatic and pointer arrays with variable bounds. - Allow debugging with pointer to array in common. - Allow sizeof(character_array(1)) - do runtime evaluation if necessary. - Be more selective on bounds checking on DATA statements (but ALWAYS check that we are "inside" the array, even if individual subscripts are not). - Get 0**0 (and 0.0**0.0, etc.) correct with "-check [no]power". - Allow INTRINSIC statement after PARAMETER statement using the intrinsic name. - Disambiguate local variable and label names in .s files. - Do argument (type) checking for mechanism general (character array as actual). - Fix two bugs in "-warn argument". Check function types, even if no arguments. Get function type correct if declared AFTER the actual function statement. - Put out better message for function value not defined by end of function. - Fix prolog (and other) locators for main program with include file (and no name). o The following changes were made to the f77 driver: - None. o The following changes were made to the run-time support: Here are the changes made in the RTL since #374. Customers may ignore the DEC-internal tracking information following the description. FDARTL375 changes between 5-Oct-1996 and 23-May-1997 in -379 to -436: * Fix DFB2598. On UNIX, doing an inquire EXISTS for a FILE which is a null name gives an incorrect True. * Fix DFB2533. Fix bugs in G format editing of non-real types, dfb2533. Problem occurs with a repeating format applied to a mix of data types. * Fix DFB2573. vfe/array interaction bug. * Fix DFB2587. READ(ADVANCE='NO',IOSTAT=) returns wrong IOSTAT for EOR. * An interaction problem when an iolist with a complex followed by an item of different type is processed was uncoverd by algorithms implemented in later compiler versions. * DFB2600. Array section in NAMELIST input generates runtime error. Add substring (m:n) support for all arrayed data types" * Fix a multi-thread corruption bug. Multiple threads writing to the same unit failed. * Support STOPs from multiple threads. * Fixed bug in intrinsic bjtest. * Add support in for_set_reentrancy routine to return current reentrancy mode for an argument of FOR_K_REENTRANCY_INFO. o Known RTL problems: * DFB2544: When a program compiled with "-convert big_endian" does an unformatted write of a very large record, the data portion gets written in big-endian order, but the four-byte header which specifies how long the record is gets written out as little-endian. o The following changes to DFAO documentation should be noted: - None. o Please note the following: - Please read the "Please note the following" sections in the attached release notes. - You only need to install one of DFARTL373 or DFARTL375: see the "Important Note about Installing DFARTLnnn" above. ******************************************************************************** © Digital Equipment Corporation 1996. All rights reserved. 6-Dec-1996 1.0 Digital Fortran for Digital UNIX Alpha Systems V4.1 These are the release notes for Version 4.1 of Digital Fortran for Digital UNIX Alpha Systems. The product name used to be DEC Fortran on OSF/1 AXP Systems. Beginning with Version 3.2C, the name of the DEC OSF/1 operating system became the Digital UNIX operating system. References to "Digital UNIX" and "DEC OSF/1" refer to the same operating system. Beginning with Version 4.0, this product became "Digital Fortran for Digital UNIX Alpha Systems" and includes both the FORTRAN-77-based DFAO compiler and the Fortran-90-based DEC Fortran 90 on Digital UNIX Alpha Systems compiler. These release notes describe changes made to the FORTRAN-77 based compiler (DFAO) and the common Digital Fortran RTL since the DEC Fortran V4.0 release. Previous version of these release notes for V4.0 and V3.8 are appended. After installation, these release notes can be found in /usr/lib/cmplrs/fort/relnotes After installation, the release notes for the Fortran-90 based compiler can be found in /usr/lib/cmplrs/fort90/relnotes If you have a field test version of DFAO T4.1, you will want to replace it with this one since the subset name for all field test versions of DFAO T4.1 is DFA*410. DFAO V4.1 will run on Digital UNIX v3.x, v4.0, or later systems. 1.1 Installation The DFAO V4.1 native software is a setld kit. It contains the following subsets: DFABASE410 Digital Fortran 77 V4.1 for UNIX Alpha Systems DFADOC410 Digital Fortran 77 V4.1 Release Notes and Man Page F9ABASE410 Digital Fortran 90 V4.1 for Digital UNIX Systems F9ADOC410 Digital Fortran 90 V4.1 Release Notes and Man Page DFACOM410 Digital Fortran V4.1 Tools and their Man Pages DFARTL373 Digital Fortran RTL #373 for Digital UNIX Alpha (f77 only) DFARTL374 Digital Fortran RTL #374 for Digital UNIX Alpha (f90 and f77) PSESHPF107 High Performance Fortran Scalar Libraries Note that DFARTL373 can be used with f77 only. DFARTL374 is used with both f90 and f77. ++++ Important Note about Installing DFARTLnnn ++++ ++++ ++++ ++++ If you tell setld to install both DFARTL373 ++++ ++++ and DFARTL374, they will install in no pre- ++++ ++++ determined order and one will overwrite the ++++ ++++ links to the other's files. Both will be ++++ ++++ listed as INSTALLED. If you now delete one, ++++ ++++ you will delete the links to the DF RTL library ++++ ++++ files and you will not be able to execute DF ++++ ++++ programs. ++++ ++++ ++++ ++++ Install only one of either DFARTL373 {for f77 ++++ ++++ use only} or DFARTL374 {for use with both f90 ++++ ++++ and f77}. ++++ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Note that the libraries {libots} in the OTABASE subset are no longer on the DFAO kit since those libraries ship with AOSF v3.0 and later. The what string in libots.a should be "T1.3-008G GEM 9 Feb 1994" or newer. 1.2 DFAO Files The following files and their what(1) strings are included in V4.1: decfort Digital Fortran 77 V4.1-92 -33BL fort Digital Fortran Compiler Driver V4.1-6 fortpr Digital Fortran Printer Driver V4.1-2 fsplit Digital Fortran Splitter V4.1-2 fpp Digital Fortran Preprocessor V1.0-1 DFARTL374 contains libFutil.a Digital Convert RTL V1.1-69 1+ 3-sep-1996 libUfor.a Digital Fortran Unsupported RTL V1.1-25 1+ 30-sep-1996 libfor.a Digital Fortran RTL V1.1-379 1+ 4-oct-1996 libFutil.so Digital Convert RTL V1.1-69 1+ 3-sep-1996 libUfor.so Digital Fortran Unsupported RTL V1.1-25 1+ 30-sep-1996 libfor.so Digital Fortran RTL V1.1-379 1+ 4-oct-1996 for_msg.cat Digital Fortran RTL Message Catalog V1.1-12 26-Apr-1996 for_main.o Digital Fortran "main" program V1.0 DFARTL373 contains libFutil.a DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.a DEC Fortran Unsupported RTL V1.1-23 1+ 5-apr-1996 libfor.a DEC Fortran RTL V1.1-346 1+ 12-jun-1996 libFutil.so DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.so DEC Fortran Unsupported RTL V1.1-23 1+ 5-apr-1996 libfor.so DEC Fortran RTL V1.1-346 1+ 12-jun-1996 for_msg.cat DEC Fortran RTL Message Catalog V1.1-11 29-Mar-1996 for_main.o DEC Fortran "main" program V1.0 The listing file version string in the page header is "Digital Fortran 77 V4.1-92" 1.3 What Has Changed in DFAO T4.1(ft1) from DFAO V4.0 o The following changes were made to the decfort compiler from edit -2 through -49: - Let in include file be listed with /list even if "-show include" not given. - Fix nesting level of INCLUDE files when INCLUDE stmnt is at end of file (and continued). - .AND. and .OR. expressions in logical IFs now evaluate left-to-right more often, find more short circiuts, and generate better code. - Allow dummy arguments to ENTRY statements to occur in the declaration phase, eg: PARAMETER SX = SIZEOF (X) where X only occurs as an ENTRY argument later. - Make it easier for the debugger to find the start of a routine. - Make CPPFILERR a warning {not an error} so that # 2000 "xxx.F" is ignored when xxx.F is not present. - Put out better information for FUNCTION/ENTRY names for debugging. - Make ALTRETOMI an informational for return with alternate label when no * in any dummy argument list. - Give better error message for bad character in octal/hex constant. - Allow I/O keywords to be blank padded (for compile time constants). - "-integer_size xxx" should affect constants in output statements, e.g. TYPE *,1,2,3. This is an incompatible change. - Give informational (BRNCHINTOBLK) for jumping into block or loop from outside: "Questionable branch into loop or block". - Give an error (INVSUBUSE) when subroutine/entry names are used as functions: "This name cannot be used as a function reference". - Make it possible to pass CHARACTER*(*) function names again. - Allow POINTER to functions/subroutines. - Allow an optional ":" between CDEC$ TITLE | SUBTITLE and the "[sub]title". - Add YEAR2000 warning for DATE/IDATE, suppressed by /WARN=NOUSAGE : "Two-digit year return value may cause problems with the year 2000". - Suppress BRNCHINTOBLK under /WARN=NOUSAGE. - Don't issue CHACONCONTD more than once per statement. - Fix variable lower bounds for second dimension so they don't cause assertions. - Give error message (BADRANDU) for incorrect arguments to RANDU: "Intrinsic RANDU arguments should be: (integer*2, integer*2, real*4)" - Catch adjutable array used as namelist element (avoid internal error). - The LEN intrinsic returns an INTEGER*8 result. CALL FOO(LEN(C)) | with argument checking on now gives "Integer/Logical*8" for type | instead of "Unknown" when FOO's argument is INTEGER*4. - Restore/enhance C(I:I) optimization for all integer types of I. - Code generation bugs were fixed in CHARACTER argument setup, register reuse, loop reductions, and backwards loops. o The following changes were made to the f77 driver: - Pass "-tune xxx" to CC. Pass "-compress" to DF and CC only on Platinum. Pass "-nocompress" to DF only. - Use environment variable DECFORT_CC as the full file spec of C compiler to execute if set. - Put "-qlc_r" on end of cc line so threaded RTL links only if -non_shared and (not -threads) and (not -pthread). o The following changes were made to the run-time support: DFARTL371 release notes 24-Jun-1996 Here are the changes made in the RTL since #369. Customers may ignore the DEC-internal tracking information following the description. * changes between 15-Feb-1996 and 2-May-1996 in -340: - The DEC FORTRAN RTL for F90 incorrectly failed to release previously allocated memory when padding F90 input. (dfb2424, CLD#TKTQ12397). - The DEC FORTRAN RTL would incorrectly go into an infinite loop when an embedded NULL character value was found while performing a list directed read operation. (dfb2331, FOR262). - The DEC FORTRAN RTL would incorrectly treat an end-of-record marker as a value separator while performing a list-directed read operation. (dfb2310, FOR145). - The DEC FORTRAN RTL incorrectly produced a "recursive I/O operation" error after a user has made a call to flush() to flush a unit which was not previously opened, then attempted to perform any I/O operation on the unit. (dfb2434, FOR719) - The DEC FORTRAN RTL for F90 would incorrectly fail to return an End-of-record error for certain non-advancing I/O operations. This occured when attempting to read into successive array elements while running out of data. (dfb2433). * changes made bewteen 3-May-1996 and 30-May-1996 in -344: - The ":" edit descriptor when at the end of the input record did not stop the RTL from reading the next record, causing errors like "input conversion". (dfb2440,FOR800) * changes made between 30-May-1996 and 13-Jun-1996 in -346: - Implied DO loops on I/O lists fail when non-native file support {-convert} is in use. (dfb2445) o The following changes to DFAO documentation should be noted: - POINTERs can now point to external routines {functions or subroutines. - Please read the documentation in the attached DFAO v4.0 release notes. - If you have Internet access and a World Wide Web (WWW) viewer, you are welcome to view the following: * The Digital Fortran 90 home page, located at the following URL: http://www.digital.com/info/hpc/f90 * The Digital Equipment Corporation home page, located at the following URL: http://www.digital.com o Please note the following: - Note this clarification about when inlining occurs: * "-inline manual" might not inline some statement functions if the functions are too big. * "-inline all" will inline statement functions that "-inline manual" won't. - In the POINTER declaration POINTER (P, ARRAY) P is not considered a variable, which means that a POINTER declaration may not appear in a STRUCTURE declaration. - When using the Fortran subroutines isatty(3f) and ttynam(3f), the Fortran I/O unit referenced must already be opened {or read from or written to} before these subroutines can return the correct tty information. - Concerning the optimization of speculative execution, full speculation support is in UNIX V4.0. It is possible to use speculation on UNIX V3.2 but only if the customer can get the objects for the __init_ots_speculate_xxx routines through "informal" {ie, non_fortran} channels. Kernel mode support for speculation was put in UNIX V3.2 so it could be tested but the the object library support did not ship in that release of UNIX. The V4.0 release includes both object library support as well as kernel mode support. - Power-of-2 sized arrays can cause cache thrashing on Alpha's direct-mapped caches. DF uses the following rules to decide whether to add padding to the end of an array to ensure that the next array will not start on exactly the same cache block (address mod 8K, the EV4 and EV5 primary cache size): * The array is "large", 8K bytes or larger * The size of the array is "almost" a power of 2, ie, it is within one cache-line (32 bytes) of being a power of 2 * The user is compiling at -O3 or higher {which means the optimizer will trade a little space for speed} If these conditions hold, DF pads the array size 32 bytes beyond the power-of-2 size. So for a program that has REAL A(64,64), B(64,64), C(64,64) DF adds 32 bytes of padding to each 16K array so that A(1), B(1), and C(1) will occupy different blocks in the Dcache. - If the array is more than 512 bytes in size but not "large" as described above, DF tries to align it on a cache-line boundary The maximum alignment on UNIX is 16-byte, so that's all DFAO can do there. - DFAO on UNIX v4.0 and newer systems generate special information for both the loader and for debugging. This new information will cause errors in ld and dbx on UNIX systems before v4.0. - There is a loader bug in UNIX v3.2C and newer that is fixed in UNIX v4.0 that prohibits a COMMON block bigger than 2GBytes from being created in an image. The "official patch" for UNIX v3.2C from the support center is "Patch ID: OSF350-143" - There is an ECO kit for DFAO v4.0 called FORTAUE01040 that contains fixes from -2 through -43. The release notes for FORTAUE01040 are dated 10-Aug-1996 and describe subsets named DFA*401. This FT kit supercedes that ECO kit and contains all bug fixes that FORTAUE01040 does. - Please read the "Please note the following" sections in the attached DFAO v4.0 release notes. 1.4 What Has Changed in DFAO T4.1(ft2) from DFAO T4.1(ft1) o The following changes were made to the decfort compiler from edit -50 through -61: - Implement DATE_AND_TIME intrinsic from Fortran-90. - Implement multiple entry point functions with mixed COMPLEX entry names. - Add "-stand semantics" warning of entry (of function) name used before ENTRY statement. - Optimize the representation of field references. - Merge I/O lists with "simple" elements into a single I/O call. - Implement "-arch ev4 | ev5 | ev56 | pca56 | generic | host". - An unused automatic data item no longer causes the compiler to abort. - Code generation bugs were fixed in "-transform_loops" and "-O4" and above. o The following changes were made to the f77 driver: - Implement "-arch" switch. o The following changes were made to the run-time support: DFARTL372 release notes 11-Oct-1996 Here are the changes made in the RTL since #371. Customers may ignore the DEC-internal tracking information following the description. * changes made between 14-Jun-1996 and 11-Oct-1996 in -347 to -379: - LOGICAL*8 data written with I format claims no support. (HPXQ90576) o Please note the following: - The -arch keyword option has been added. This option determines the type of Alpha chip code that will be generated for this program. The -arch keyword option uses the same keywords as the -tune keyword option. Whereas the -tune keyword option is primarily used by certain higher-level optimizations for instruction scheduling purposes, the -arch keyword option determines the type of code instructions generated for the program unit being compiled. Digital UNIX Version 4.0 and subsequent releases provide an operating system kernel that includes an instruction emulator. This emulator allows new instructions, not implemented on the host processor chip, to execute and produce correct results. Applications using emulated instructions will run correctly, but may incur significant software emulation overhead at runtime. All Alpha processors implement a core set of instructions. Certain Alpha processor versions include additional instruction extensions. Supported -arch keywords are as follows: - -arch generic generates code that is appropriate for all Alpha processor generations. This is the default. Running programs compiled with the generic keyword will run all implementations of the Alpha architecture without any instruction emulation overhead. - -arch host generates code for the processor generation in use on the system being used for compilation. Running programs compiled with this keyword on other implementations of the Alpha architecture might encounter instruction emulation overhead. - -arch ev4 generates code for the 21064, 21064A, 21066, and 21068 implementations of the Alpha architecture. Running programs compiled with the ev4 keyword will run without instruction emulation overhead on all Alpha processors. - -arch ev5 generates code for some 21164 chip implementations of the Alpha architecture that use only the base set of Alpha instructions (no extensions). Running programs compiled with the ev5 keyword will run without instruction emulation overhead on all Alpha processors. - -arch ev56 generates code for some 21164 chip implementations that use the byte and word manipulation instruction extensions of the Alpha architecture. Running programs compiled with the ev56 keyword might incur emulation overhead on ev4 and ev5 processors, but will still run correctly on Digital UNIX Version 4.0 (or later) systems. - -arch pca56 generates code for the 21164PC chip implementation that uses the byte and word manipulation instruction extensions and multimedia instruction extensions of the Alpha architecture. Running programs compiled with the pca56 keyword might incur emulation overhead on ev4 and ev5 and ev56 processors, but will still run correctly on Digital UNIX Version 4.0 (or later) systems. - "ev56" and "pca56" have been added to the architecture keywords that "-tune" accepts. 1.5 What Has Changed in DFAO T4.1(ft3) from DFAO T4.1(ft2) o The following changes were made to the decfort compiler from edit -62 through -75: - Implement DATE_AND_TIME intrinsic from Fortran-90. - Fix nested uninitialized structure bug. - Allow CHARACTER *(*) C; PARAMETER (C='abcdefghijk'). - Better "function type" message string when mismatch between caller and called function. - Give warning instead of assertion for REAL*4 X(10); REAL*8 X. - Fix IBITS on small integers so it doesn't overflow. - Do NOT allow VOLATILE to apply to a function name. - Cray pointers made usable in ladebug. - Fix illegal memory reference in compiler when the I/O format is a CHARACTER function. o The following changes were made to the f77 driver: - None. o The following changes were made to the run-time support: - DFARTL373 is DFARTL371 labeled for f77 only. - DFARTL374 is DFARTL372 labeled for f90 and f77. o Please note the following: - Prior to Digital UNIX v4.0, the default dynamic rounding mode was round-to-infinity but with DUNIX v4.0 and later, the default rounding mode is round-to-nearest. This change in rounding mode may cause some differences in floating point results if you use dynamic rounding modes. - The "cc" command in Digital UNIX v4.0 accepts -shared (and does the right thing), but is not documented in the cc(1) man page. - The documentation for the for_rtl_init_ routine does not describe the arguments to for_rtl_init_. When the main program is a C program that calls Fortran subprograms, the main C program should call the for_rtl_init_ routine, which allows Fortran subprograms to properly use the DEC Fortran RTL. The following should be added to the above: The C function prototype for for_rtl_init_ is as follows: void for_rtl_init_ ( int *argc, /* Access: Read. # of args to the main program */ char *argv[] /* Access: Read. Pointer to the list of args */ ); Note: Unlike a main C function, the first argument, argc, is passed by address. The following is an example of how to use the for_rtl_init_ routine from a main C function. int main ( int argc, char *argv[] ) { extern void for_rtl_init_( int *rtl_argc, char *rtl_argv[] ); extern void my_fortran_subroutine( void ); for_rtl_init_( &argc, argv ); my_fortran_subroutine(); return( 1 ); } 1.5 What Has Changed in DFAO V4.1 from DFAO T4.1(ft3) o The following changes were made to the decfort compiler from edit -76 through -92: - Fix IBITS to not overflow on small integer types. - Fix (another) NAMELIST/SAVE/EQUIVALENCE problem. - Use less memory at compile-time for routine prolog code for adjustably dimensioned arrays (a(n,n),b(n,n)). - Fix a.b.c offset computation. - Omitted value for "-source_include" was incorrect. "-assume " caused "-assume nosource_include". - Fix listing for "-tune" and "-arch" to give the ACTUAL values used by the backend. - "Small integer*1 op small integer*2 constant" should give integer*1 result (ala VAX). - Change error message for YEAR2000 (suggest using DATE_AND_TIME, not DATE). - Data initialization incorrect for: "RECORD /S1/R1,/S2/R2" (r2 used s1 initialization). - Do not allow substrings to be merged in I/O lists (N,STR(1:N) for example). o The following changes were made to the f77 driver: - None. o The following changes were made to the run-time support: - none o Please note the following: - You only need to install one of DFARTL373 or DFARTL374: see the "Important Note about Installing DFARTLnnn" above. - The DATE_AND_TIME intrinsic from the Fortran 90 standard has been added to DFAO to allow users to get to a 4-digit year in order to properly handle dates starting in the year 2000. Here is the interface specification for DTE_AND_TIME: DATE_AND_TIME ([date] [,time] [,zone] [,values]) Class: Subroutine Returns character data on the real-time clock and date in a form compatible with the representations defined in Standard ISO 8601:1988. Optional arguments (all are INTENT(OUT), ie, will be modified by calling DATE_AND_TIME): o The "date" must be scalar and of type default character; its length must be at least 8 to contain the complete value. Its leftmost 8 characters are set to a value of the form CCYYMMDD, where: CC is the century YY is the year within the century MM is the month within the year DD is the day within the month o The "time" must be scalar and of type default character; its length must be at least 10 to contain the complete value. Its leftmost 10 characters are set to a value of the form hhmmss.sss, where: hh is the hour of the day mm is the minutes of the hour ss.sss is the seconds and milliseconds of the minute o The "zone" must be scalar and of type default character; its length must be at least 5 to contain the complete value. Its leftmost 5 characters are set to a value of the form + or - hhmm, where "hh" and "mm" are the time difference with respect to Coordinated Universal Time (UTC) in hours and parts of an hour expressed in minutes, respectively. o The "values" must be of type default integer and of rank one. Its size must be at least 8. The values returned in "values" are as follows: values (1) is the 4-digit year values (2) is the month of the year values (3) is the day of the year values (4) is the time difference with respect to Coordinated Universal Time (UTC) in minutes values (5) is the hour of the day (range 0 to 23) values (6) is the minutes of the hour (range 0 to 59). values (7) is the seconds of the minute (range 0 to 59). values (8) is the milliseconds of the second (range 0 to 999). Example: Consider the following example executed on 1993 April 23 at 13:23:30.5: INTEGER DATE_TIME (8) CHARACTER*12 REAL_CLOCK (3) CALL DATE_AND_TIME (REAL_CLOCK (1), REAL_CLOCK (2), ! continued REAL_CLOCK (3), DATE_TIME) This assigns the value "19930423" to REALCLOCK (1), the value "132330.500" to REALCLOCK (2), and the value "+0100" to REALCLOCK (3). The following values are assigned to DATETIME: 1993, 4, 23, 60, 13, 23, 30, and 500. ******************************************************************************** © Digital Equipment Corporation 1996. All rights reserved. 12-Mar-1996 1.0 Digital Fortran for Digital UNIX Alpha Systems V4.0 These are the release notes for Version 4.0 of Digital Fortran for Digital UNIX Alpha Systems. The product name used to be DEC Fortran on OSF/1 AXP Systems. Beginning with Version 3.2C, the name of the DEC OSF/1 operating system is now called the Digital UNIX operating system. References to "Digital UNIX" and "DEC OSF/1" refer to the same operating system. Beginning with Version 4.0, this product became "Digital Fortran for Digital UNIX Alpha Systems" and includes both the FORTRAN-77-based DFAO compiler and the Fortran-90-based DEC Fortran-90 on Digital UNIX Alpha Systems compiler. These release notes describe changes made to the FORTRAN-77 based compiler (DFAO) and the common Digital Fortran RTL since the DEC Fortran V3.8 release. The release notes for the Fortran-90 based compiler can be found in /usr/lib/cmplrs/fort90/relnotes If you have a field test version of DFAO T4.0, you will want to replace it with this one since the subset name for all field test versions of DFAO T4.0 is DFA*400. DFAO V4.0 will run on AOSF v3.x or later systems. DFAO V4.0 will no longer run on AOSF 2.x systems. DFAO V4.0 will run on AOSF V4.0. 1.1 Installation The DFAO V4.0 native software is a setld kit. It contains the following subsets: DFABASE400 Digital Fortran 77 V4.0 for UNIX Alpha Systems DFADOC400 Digital Fortran 77 V4.0 Release Notes and Man Page F9ABASE400 Digital Fortran 90 V4.0 for Digital UNIX Systems F9ADOC400 Digital Fortran 90 V4.0 Release Notes and Man Page DFACOM400 Digital Fortran V4.0 Tools and their Man Pages DFARTL369 Digital Fortran RTL #369 for Digital UNIX Alpha PSESHPF107 High Performance Fortran Scalar Libraries Note that the libraries {libots} in the OTABASE subset are no longer on the DFAO kit since those libraries ship with AOSF v3.0 and later. The what string in libots.a should be "T1.3-008G GEM 9 Feb 1994" or newer. 1.2 DFAO Files The following files and their what(1) strings are included in V4.0: decfort Digital Fortran 77 V4.0-1 -3231 fort DEC Fortran Compiler Driver V4.0-1 fortpr DEC Fortran Printer Driver V4.0-1 fsplit DEC Fortran Splitter V4.0-12 fpp DEC Fortran Preprocessor V1.0-1 libFutil.a DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.a DEC Fortran Unsupported RTL V1.1-22 1+ 1-nov-1995 libfor.a DEC Fortran RTL V1.1-329 1+ 14-feb-1996 libFutil.so DEC Convert RTL V1.1-65 1+ 30-aug-1995 libUfor.so DEC Fortran Unsupported RTL V1.1-22 1+ 1-nov-1995 libfor.so DEC Fortran RTL V1.1-329 1+ 14-feb-1996 for_msg.cat DEC Fortran RTL Message Catalog V1.1-9 19-Jun-1995 for_main.o DEC Fortran "main" program V1.0 The listing file version string in the page header is "Digital Fortran 77 V4.0-1" 1.3 What Has Changed in DFAO V4.0 from DFAO V3.8 o The following changes were made to the decfort compiler: - Handle underflows/overflows in floating point constants - Warnings only. - Fix the location of I/O statements for debugging - eg, don't jump to the FORMAT while stepping through a READ. - An AUTOMATIC declaration is ignored on what is really an f90 style automatic array. - Fix parameter constants of type LOGICAL for debugging. - Allow intrinsic DPROD to accept double precision arguments so it will work correctly under -real_size 64. - Make DPROD give standards warning for real*8 arguments. - An ACCVIO may occur when getting a listing that contains lots of PSECTs. - Implement CDEC$ OPTIONS /[NO]WARNINGS[=[NO]ALIGNMENT]. - Implement "-reentrancy none | asynch | threaded". See the f77(1) man page for more information. - Recognize f90 LMF names as well as f77. Listing header and compiler name == "Digital Fortran 77" - Fix ENCODE with substring with /CHECK=BOUNDS. Enhance/fix bounds checking for substrings. - Fix nested arrays in I/O "collapsed" list such as: TYPE *,(A(M(2),I),I=1,3). - Optimize 4 calls to SQRT into one math library call. - Allow "-check=all" together with OPTIONS /CHECK=NOUNDERFLOW. - With "-stand semantic", give informational for FILE= with STATUS='SCRATCH'. - Give error (not assertion) for (too) large format - like F800.400 . - Add variable to MISALIGN message. - Enhance actual/formal checking when actual is an integer/logical constant. - Handle underflows/overflows in floating point constant strings: give warnings only. - Make intrinsics LEN and SIZEOF return values as INTEGER*4 or *8, depending on platform. - Support for .s assemblable files via the -S command line option. - Add AOSF message that PSECT ALIGN can't be > 4. - Improve generated code for POINTER variables. - Give better error message for include 'foo(module)'. - Add -[no]pipeline. - Add -[no]transform_loops. - Allow large CHARACTER*(*) arrays in I/O statements - compute size correctly. - Implement the CDEC$ RESTRICT directive. - Under "-warn argument_checking", report actual/caller function type mismatch. - With "-check overflow", code is now continuable after integer overflow. - A warning is issued if a STRUCTURE definition is empty. A warning is issued if a RECORD declaration would result in an empty RECORD; the RECORD is made to have a length of 1 byte. - Fix problem of INCLUDE and -pad_source. - For block IF statement, defer creation of "last" label until we know we need it. - Namelist variables are STATIC (even when equivalenced into a namelist block). - Full 32 bit positive integers (with sign bit on) are integer*8 (not integer*2). - Change INTVARREQ to INVTYPUSE on USEROPEN not type integer. - Allow better debugging of bounds checking code. - Allow "what" text for Main program or if there is an IDENT. Use -ident to require "what" text in all modules. - Check general actual arguments against formal parameters for type mismatch. - Allow VOLATILE for pointee - implement by marking pointeR as VOLATILE instead. - Add new message STKALLEXC: allocations to stack exceeded maximum stack size. - Stack verification is now ON on Alpha always. - All UNIX-like "what" string in all product .EXEs. - Character CASE statement does not check for overlapping ranges properly - various problems. - Restore the substr(I:I) optimization. - Disallow real*16 function declarations on targets not supporting real*16. - Make ASF record formals be scalar (dimensionality not inherited). - Allow OPTIONS /ASSUME=[NO]UNDERSCORE (all platforms). - Let IDATE take I*8 arg on Alpha; make SECNDS generic in floating arg: FDGSTX. This requires an AVMS FORRTL newer that v6.2. - Do NOT data initialize pointee records (ignore the structure initialization). - Allow DO,WHILE (allow the optional comma) like Fortran 90. - Check that upper bound of a substring is GEQ the lower bound when /check=bounds. - "-nospeculate" now means the same as "-speculate none". - The optimization of calling the "reciprocal square root" routine in the 1.0/SQRT(...) case will be conditionalized on the "-assume noaccuracy_sensitive" option. So the new rules will be 1. -switch [no]sqrt_recip is no longer supported 2. DFA computes A/sqrt(B) using recip sqrt *unless* -assume accuracy_sensitive (the default) 3. DFAO computes 1.0/sqrt(B) using recip sqrt *unless* -assume accuracy_sensitive (the default) o The following changes were made to the f77 driver: - Add "-reentrancy xxx", "-noreentrancy"; check for "-threads"; If "-non_shared", put "-qlc_r" on end of cc line so threaded RTL links. - DECFORT_INIT can be used to automagically set compiler flags. - Accept -S for .s file support. - Add -ident, -noident, alias -no_fp_reorder to -assume accuracy. - -f66 as alias for -nof77, -what support. - Accept -[no]transform_loops, -[no]pipeline. - Pass -lm_4sqrt to linker if /usr/lib/libm_4sqrt.a exists and environment variable is not DECFORT_4SQRT==FALSE (or false). - On a Digital UNIX V4.x system automatically set a compiler flag enabling some operating-system specific fixes. This can be disabled if the environment variable DECFORT_NOPLATINUM==TRUE. - Some cleanup was done to detect missing arguments for command line options at the end of the command line. o The following changes were made to the run-time support: This covers changes to the Digital Fortran RTL for both Digital Fortran 77 and Digital Fortran 90 since DEC Fortran V3.8 was shipped: - The Digital Fortran RTL fixed a memory leak that showed up with the Digital Fortran 90 compiler and the OPEN=PAD construct. - The Digital Fortran RTL has made some improvements to the handling of floating point IEEE exceptions. - The Digital Fortran RTL incorrectly produced an "FOR-F_LISIO_SYN" error message for certain Internal list-directed read operations. - The Digital Fortran RTL failed to produced an error condition during a list-directed write operation if the disk space for the file was already exhausted. - The Digital Fortran RTL was built so that it would cause the debugger to step into the Digital Fortran RTL code instead of over the Digital Fortran RTL code when the user issued the debugger "step" instruction. The Digital Fortran RTL has been built so that this will nolonger happen. - The Digital Fortran RTL gave incorrect results for the TTYNAME and ISATTY routines when the unit specified was not previously opened. - The Digital Fortran RTL incorrectly produced a negative value when the Q descriptor was specified in a format statement instead of a zero value. This behavior was different than the VAX FORTRAN RTL behavior. This has been corrected and the Digital Fortran RTL behavior is now consistent with the VAX FORTRAN RTL behavior. - The Digital Fortran RTL incorrectly produced an "ENDDURREA" error message for list-directed reads. This would occur when the user specified a list of items which contained adjacent commas which were separated by leading and trailing whitespace. - The Digital Fortran RTL has made some improvements to the handling of floating point exceptions. - The Digital Fortran RTL incorrectly returned the actual unit number specified in the inquire statement using Digital Fortran 90 when the unit was not connected. Now the Digital Fortran RTL correctly returns -1, as required by the Fortran 90 standard. - The Digital Fortran RTL incorrectly produced a "VFEVALERR" error when a zero value was specified for the X, TR and TL format codes. This was inconsistent with the VAX FORTRAN RTL behavior. This been correct and the Digital Fortran RTL behavior is now consistent with the VAX FORTRAN RTL behavior. - The Digital Fortran RTL using the Digital Fortran 90 compiler incorrectly returned rewind in the inquire statement for files that were opened with position='asis'. - The Digital Fortran RTL incorrectly produced an "infinite format loop" error message, using Digital Fortran 90, when an empty format specification was specified, and the corresponding item list or list of items all had zero size. - The Digital Fortran RTL when using Digital Fortran 90 would sometimes go into an infinite loop when an index back option was requested. - The Digital Fortran RTL when using Digital Fortran 90 would produce unexpected behavior for a nonadvancing formatted read followed by a list directed read, again followed by a nonadvancing formatted read, all to the same unit. - For files opened for direct access,"fixed length records", the RTL would incorrectly output an error message if there was a trailing X format statement which happened to output the exact number of spaces remaining in the fixed length record - During exit handler processing, if a unit was previously open and not closed before receiving a control-Y the Digital Fortran RTL would loop - The Digital Fortran RTL would output a extra blank line when the last item was a zero trip implied do-loop (ie.; with n=1,0,"zero elements") - The Digital Fortran RTL would give a different IOSTAT value from the VAX FORTRAN RTL for VFE values which are out of range - The Digital Fortran RTL VFE behavior no longer differs from the VAX FORTRAN RTL behavior. - The Digital Fortran RTL incorrectly recognized null repeat values for list-directed I/O - The Digital Fortran RTL fails to re-enable interrupts causing a running program to ignore control-C - The Digital Fortran RTL failed to completely initialize some extended formatted records with blanks - The Digital Fortran RTL incorrectly produced an input conversion error (INPCONERR) for some small integer conversions - The Digital Fortran RTL SECNDS function failed to account for daylights saving time o The following changes to DFAO documentation should be noted: - The rules for G format switching between E and F formats has been refined as part of the Fortran 90 standardization process. The new rules say if 0 < N <= 0.1 - 0.5 x 10**(-d-1) or N >= 10**d - 0.5, then treat as kPEw.d. For N = 0.0996 and -1PG11.3, we now get 0.0996 <= 0.09995 so use kPEw.d which gives 0.010E+01. We used to kPFw.d and get 0.100 . o Please note the following: - The Digital Fortran RTL on the Digital UNIX System Integrated Products CD-ROM is documented in the Installation Guide, appendix D. The software appears in the directory ALPHA/DEC_Fortran_RTL - -warn arg does limited argument checking between caller and callee when they are compiled within the same unit. Specifically, it checks that the data types match between the call and the declaration and checks the size of literals (ie, 0.0 passed to a REAL*8). It does not check that the number of arguments being passed matches the number declared. - If your program has a variable that is referenced asynchronously, either by another thread or by a called routine, it is safest to declare that variable as VOLATILE to prevent some optimizations from misusing the variable. Although using the %LOC construct may work most of the time, VOLATILE imposes stronger constraints. - If you have declared multiple DATA statements for the same variable the compiler will use the LAST definition seen within a single compilation. If you have multiple initializations and separate compilations the results are unpredictable. - CDEC$ OPTIONS /[NO]WARNINGS[=[NO]ALIGNMENT] The "CDEC$ OPTIONS" directive has been extended to accept /WARNINGS[=[NO]ALIGNMENT] /NOWARNINGS to turn off or on the local reporting of alignment warnings in STRUCTUREs or COMMONs. - If you want to be able to use another compiler after installing this one, the installation procedure creates a command file f77_nnn when DFAnnn is installed, that will invoke the correct driver and compiler. If you do nothing else, both f77_nnn and f77 will use the same RTL. If you want to use a different RTL, there is an environment variable to point to the different RTLs: setenv DECFORT_LIB_DIR /usr/lib/cmplrs/fortrtl_nnn - The documentation in the USEROPEN section of the User Manual describes what is illegal inside a USEROPEN, but it could be clearer. The cardinal rule of USEROPEN routines is to leave the FAB/RAB/XAB chains exactly as they were when the USEROPEN routine was called. The second rule is to use the existing blocks rather than replacing them with your own. - For variables in COMMON, it is important to name in a VOLATILE statement any variables or COMMON blocks which can be referenced (either read or written) other than by direct reference or during a routine call. For example, if a variable in COMMON is referenced in an OpenVMS AST routine, condition handler or exit handler, or is in a shared global section, you must declare as volatile that variable, or the COMMON block to which it belongs. See the DEC Fortran Language Reference Manual for more information on the VOLATILE statement. - Please note that in formatted, list-directed, and NAMELIST input of logical values, any string that starts with "F" is accepted as .FALSE. and any string that starts with "T" is accepted as .TRUE. - The IOSTAT values are listed in the DF help file {it's installed as /usr/lib/cmplrs/fort/decfortran.hlp on UNIX}. The file is organized like a VMS help file so you need to look for a line that starts 2 Error_Messages and then search for the IOSTAT number {eg, 35}: o MESSAGE: Segmented record format error NUMBER: 35 EXPLANATION: An invalid segmented record control data word was detected in an unformatted sequential file. The file was probably either created with RECORDTYPE='FIXED' or 'VARIABLE' in effect, or was created by a program written in a language other than Fortran. - DFAO by default gives an error at run-time for the run-time computation of 0.0**0.0 and ** {eg, (-3.0)**3.0}. To get the semantics of the C language, where 0.0**0.0 is 1 and (-3.0)**3.0 is -27, use the "-check nopower" commmand line option to turn off such error checking in the power routines. - More improvements in the arithmetic computations used during compile-time. When a floating-point evaluation at compile-time overflows or would result in an IEEE NaN, the value used at compile-time is now the correctly signed Infinty or NaN. Similarly, denormalized values are used on underflow. This more closely the run-time behavior at -fpe3 but must be used carefully at -fpe0 {the default} where such values may signal errors. - The new directive CDEC$ RESTRICT pointee [, pointee]... CDEC$ RESTRICT * advise the compiler that objects pointed to using the POINTER statement are not accessed by any other name that the name in the POINTER statement {"pointee" above}. "*" means all such pointees are exclusively accessed by their pointee name. This allows for better optimizations of objects pointed to because the compiler can assume the only way to access the object is by its pointee name and no other. - If you encounter the following ld error on Digital UNIX v3.2 > $ f77 -o x x.f > Assertion failed: 0, file > ./../../../../../src/usr/ccs/lib/libmld/cmrlc_produce.c, line 864 > Fatal error in: /usr/lib/cmplrs/cc/ld IOT/Abort trap - core dumped > fort: Severe: Failed while trying to link. you can call your customer service representative and ask for patch ID OSF320-094. This will provide you with a new linker that solves the problem. As a work around, you can link with the -O1 switch like this: $ f77 -O1 -o x x.f - Interesting command line options available in the f77 driver {see the f77(1) man page for more information}: * -what displays the what strings for the driver and the compiler {and the preprocessor if DECFORT_FPP is set} * -O5 now performs loop transformations {unless you use -notransform_loops} as well as software pipeling {unless you use -nopipeline} * -transform_loops Activates a group of loop transformation optimizations that apply to array references within loops. The types of optimizations associated with -transform_loops include the following: + Loop blocking + Loop distribution + Loop fusion + Loop interchange + Loop scalar replacement + Outer loop unrolling * -assume byterecl Tells the compiler to tell the RTL that an explicit RECL value in an OPEN statement is in units of bytes {the default is units of longwords} INQUIRE returns RECL= in bytes if the unit is not open; in lonwords if the file is open for unformatted and there is no "-assume byterecl"; otherwise, in bytes. * -speculate by_routine Indicates that all routines in the current module can do speculation but that this speculation cannot effect routines in other modules in the program. * -ident places what(1) style identification into the object file * -S creates an assemblable listing file {xxx.s} - The largest data alignment allowed by ld(1) is 2**4; anything bigger in the "CDEC$ PSECT" directive will warn: The val in 'ALIGN=val' must be an integer ranging from 0 through 4. [actual-value-present] - The following program shows a problem with DFAO: PROGRAM X IMPLICIT NONE INTEGER*2 Y(ICHAR('A'):ICHAR('Z')) INTEGER*4 Z Z = ICHAR('A') END reports a compile-time error of "untyped name ICHAR" in the Y declaration. The work-around is to declare the intrinsic: INTEGER*4 ICHAR - If you want to determine if the compiler allocated a data object as static or automatic, look in the VARIABLES (or ARRAYS) section at the end of the listing, find the variable in question, and look at the "Address". It will have a digit (a PSECT number), a dash, and then an address. If the PSECT number is zero, it was allocated on the stack, if 1 or 2, it was allocated statically. - A new optimization present in DFAO V4.0 necessitates the need for a new math library function, currently not working in all versions of libm. The optimization involves computing 4 values of the SQRT intrinsic in one library call: the f77 driver check to see if the file /usr/lib/libm_4sqrt.a is present {it is installed by DFABASE400}; if it is and the environment variable DECFORT_4SQRT is not "F", then "-lm_4sqrt" is added to the ld line to access this library. - There is a restriction that is not explicitly enforced by DFAO: if you use dbx or DECladebug to debug a Fortran program whose main program is named "MAIN", ie, "PROGRAM MAIN", the debugger will not be able to find the starting instruction. - shcom(3f) can be used to create writable shared COMMON blocks. If you have large arrays to be shared, it helps to initialize them in a BLOCK DATA routine that is used to create the shared COMMON. - The full release notes for DFAO v3.8 are attached below for your information. Changes that affect those release notes are marked with 2 vertical bars "||" in the left margin. ******************************************************************************** 21-Apr-1995 1.0 DEC Fortran for OSF/1 AXP Systems These are the release notes for version 3.8 of the DEC Fortran on OSF/1 AXP compiler system. In what follows, DFAO refers to the DEC Fortran product on OSF/1 AXP. If you have a field test version of DFAO v3.x or any version of DFAO that is older than this one, you will want to replace it with this one or later and recompile and relink any Fortran programs that used these older versions. DFAO v3.8 contains a native compiler that runs on and generates code that will run on OSF/1 AXP v3.x. The code is native OSF/1 AXP code in the 64-bit addressing environment. The run-time libraries for DFAO code support are provided in both shared and static form. The f77 command can be used to compile and link Fortran files with the proper libraries. There is an f77(1) man page installed that documents all of the features of the driver. 1.1 Installation The DFAO V3.8 native software is a setld kit. It contains the following subsets: DFABASE380 DEC Fortran V3.8 for OSF/AXP Systems DFADOC380 DEC Fortran V3.8 Release Notes DFACOM380 DEC Fortran V3.8 Tools and their Man Pages OTABASE105 DEC Compiled Code Support Library DFARTL360 DEC Fortran for OSF/AXP Runtime Support Note that the libraries {libots} in the OTABASE subset are the same versions as those that now ship with AOSF v3.0 and later. OTABASE105 will decline installation on AOSF v3.x even though "setld -i" will not list it as an installed subset; OTABASE105 will state that the correct libraries are present, which they are. 1.2 DFAO Files The following files and their what(1) strings are included in V3.8: decfort PFORT V3.8-711 -293V fort DEC Fortran Compiler Driver V3.8-064 fortpr DEC Fortran Printer Driver V3.8-005 fsplit DEC Fortran Splitter V3.8-11 fpp DEC Fortran Preprocessor V1.0-1 libFutil.a DEC Convert RTL V1.1-57 1+ 27-oct-1994 libUfor.a DEC Fortran Unsupported RTL V1.1-20 1+ 5-dec-1994 libfor.a DEC Fortran RTL V1.1-248 1+ 20-apr-1995 libots.a libots.a T1.3-008G GEM 9 Feb 1994 libFutil.so DEC Convert RTL V1.1-57 1+ 27-oct-1994 libUfor.so DEC Fortran Unsupported RTL V1.1-20 1+ 5-dec-1994 libfor.so DEC Fortran RTL V1.1-248 1+ 20-apr-1995 libots.so libots.a T1.3-008G GEM 9 Feb 1994 for_msg.cat DEC Fortran RTL Message Catalog V1.1-8 13-Mar-1995 for_main.o DEC Fortran "main" program V1.0 The listing file version string in the page header is "DEC Fortran V3.8-711" 1.3 What Has Changed in DFAO v3.8 from DFAO v3.7 o Interesting Information about DFAO v3.8 - Note that the default for "-inline" was supposed to be "speed" in DFAO v3.7. In the final release of v3.7, the default is "-inline space". That has been repaired in DFAO v3.8: the default for "-inline" is once again "speed". o The following changes were made to the decfort compiler: - Do not abort when user erroneously declares an external (function) name volatile. - Add an informational message for automatic arrays when user says /stand. - Upgrade support for cpp # line directives to be ANSI compliant. - Ignore labels in a BLOCK DATA subprogram. - Allow MVBITS to use in-lined code to handle large, unknown, zero, or negative sizes. - Be more efficient at compile-time with constant subscripted routine actual arguments. - Do not abort on multiply-defined structures. - Make FOO() OK, even with "-stand syntax". - Do not abort on zero-length COMMON. - Fix DFAO so a labeled ENDDO no longer incorrectly closes both unlabeled and labeled DO statements. - Do not abort on a weird combination of invalid program plus "-warn declarations". - Allow interesting cases of constant folding to work (FLTDIV, lots of exceptional cases), especially for parameter constants, even at -fpe0. Allow: parameter NAN=0.0/0.0. - PARAMETER(X=intrinsic()) didn't give a warning if /standard. - For -r16, add lots of conversions of intrinsic names. - "-inline space" change to "-inline size". - Allow AUTOMATIC variables to be EQUIVALENCEd. Detect conflicts in this area. - Keep inlining of REAL*16 function names from blowing up. o The following changes were made to the f77 driver: - None for this kit. o The following changes were made to the run-time support: - A $ format descriptor at the beginning of the FORMAT no longer gets an INVARGFOR error. - Namelist input of a 'T' or an 'F' where CHARACTER data was expected no longer aborts the execution. o The following changes to the DFAO documentation should be noted: - None for this kit. o Please note the following: - The documentation in the f77(1) man page has been fixed to reflect the DFAO implementation of warnings on unused variables: "-warn nounused" is the default so messages about unused variables do not appear unless you specify "-warn unused". - There is a restriction that is not explicitly enforced by DFAO: if you use dbx or DECladebug to debug a Fortran program whose main program is named "MAIN", ie, "PROGRAM MAIN", the debugger will not be able to find the starting instruction. - The behavior of a default file OPEN is to open the file for both READ and WRITE access. If that fails {eg, the file is READONLY}, then the OPEN tries to open the file for READ access only. If you use the -vms command line switch, you do not get the behavior described above: the file is opened for READ and WRITE access; if that fails, the OPEN fails and an error is reported. - Arithmetic at compile-time now behaves according to IEEE rules and the -fpe command line switch. For example: Fortran source Behavior X = 0./0. Code is generated so the run-time behavior conforms to the -fpe setting REAL NAN For all settings of -fpe, NAN is PARAMETER (NAN = 0./0.) set to the IEEE exceptional value NaN. PARAMETER (DNORM = 1E-30/1E10) For -fpe3 and above, DENORM is set to the denormalized value 1E-40; for -fpe0, 1, 2, DENORM is set to 0.0 - Notice that IEEE arithmetic precludes certain optimizations. At -fpe1 or higher, the following transformations are no longer performed at compile-time since they could raise an exception at run-time: Add(X,0) => X Add(X,-X) => 0 Sub(X,0) => X Sub(X,X) => 0 Mul(X,0) => 0 Mul(X,1) => X Div(X,1) => X Div(0,X) => 0 Div(X,X) => 1 Eql(X,X) => .true. Geq(X,X) => .true. Leq(X,X) => .t. For example, consider Mul(X,0). At -fpe0, the answer is 0, but according to the ieee standard, Mul(Infinity,0) -> NaN and Mul(NaN,0) -> NaN. So at -fpe1 or higher, the Mul(X,0) will be evaluated at run-time so IEEE semantics may be applied. 2.0 Interesting Information About DFAO Here is some interesting information about DFAO: 2.1 64 bit POINTERs In DFAO a POINTER is 64-bits. Addresses in ALPHA/OSF are 64-bits unless the executing image is forced into the low 2GB of memory using the "-T" and "-D" options to ld(1). If a POINTER is stored into an INTEGER*4, the value will be truncated and data will be lost. Store POINTERs into INTEGER*8 variables. See the "-i8" command line option also. 2.2 Run-Time Message Catalog Not Found Executing code compiled by DFAO uses the DFAO RTL. When the DFAO RTL encounters an error, it displays a message from its message catalog, for_msg.cat, installed as part of the installation of the DFAO product. If the DFAO RTL to be unable to find the message catalog, it displays a message to that effect. If that occurs, the work-around is to define NLSPATH to be the American English locale: setenv NLSPATH "/usr/lib/nls/msg/en_US.ISO8859-1/%N" so the message file can be located. If you are logged in as root, NLSPATH is ignored. In this case, you can instead set the environment variable LANG to part of the path given above. 2.3 Static Array Offsets Must Be Smaller than 32-bit Integers - Dynamic Offsets May Exceed 32-bit Values There is a restriction currently in the DFAO compiler. The restriction is that an array offset for a statically allocated array must fit in 32 bits (signed). An "array offset" is the byte offset from the array's virtual origin. This restriction goes along with the restriction that no addressable statically allocated object, eg, array or COMMON block, can be bigger (in bytes) than 32-bits. Array index calculations in DFAO V3.4 and later are done using 64-bit integer calculations (V3.3 used 32-bit arithmetic for these calculations). This means that you can have dynamically-allocated arrays that exceed 2**31 bytes in total size (arrays whose storage is gotten by calling malloc, for example). It is *not* yet possible to have statically allocated arrays this large. You can't declare an array larger than 2**31 bytes in total size. These are *not* supported: INTEGER BIG_ARRAY_1D (2**30) INTEGER BIG_ARRAY_2D (2**26, 32) The same restriction applies to adjustable arrays. For example, this is *not* supported: CALL SUB (A, 2**26, 32, 10) ... SUBROUTINE SUB (A, I, J, K) INTEGER*8 I,J,K REAL A (I,J,K) This is ok: CALL SUB (A, 2**33) ... SUBROUTINE SUB (A, A_SIZE) INTEGER*8 A_SIZE REAL A (1) 2.4 delay_wbuffers - a potential slowdown for direct access I/O There's a flag that was introduced in OSF/1 AXP to change the writeback buffer cache algorithms. It introduces delayed buffer cache writes and is particularly effective in programs that randomly read and write small files (fit in buffer cache). What's going on is that the write of a block from the cache results in the block being unavailable for reading while the write is in progress. In pathological cases this reduces reads and writes to disk speeds. The name of the flag is "delay_wbuffers". When it is on (ie, has the value 1), it delays writing modified buffers. If the flag is off (the default), Fortran programs that read and write the same direct access, small records, over and over again, may run very slowly. Fortran programs that read or write large records and never touch the same record twice may run faster. See the system documentation on how to set or reset delay_wbuffers. 2.5 HPARITH Traps DFAO now supports IEEE exceptional values (NaNs, Infs, denorms) but does not provide much assistance with user-written exception handlers that need to decode the instruction stream. See -fpe in f77(1) for DFAO's support for IEEE exceptional values. The command line option "-synchronous_exceptions" will force the compiler to generate a TRAPB instruction after every floating point instruction. This reduces performance but it allows the user to trap "high performance arithmetic" exceptions in dbx and find the offending instruction. 2.6 Fast or Accurate Math Routines The -math_library {accurate | fast} option allows you to choose between two alternate implementations of certain intrinsic functions. If you omit -math_library fast, the compiler uses the standard, very accurate math library routines for each DEC Fortran intrinsic function, such as SQRT. To use a special version of certain math library routines that produce faster results, but with a slight loss of precision and less exception checking, specify -math_library fast for your program. -math_library accurate Using -math_library accurate (default) produces the very accurate results and error checking expected of quality compiler products by using the standard set of math library routines for the applicable intrinsics. The standard math library routines are designed to obtain very accurate "near correctly rounded" results and also provide the robustness needed to check for IEEE exceptional argument values, rather than achieve the fastest possible run-time execution speed. Using -math_library accurate allows user control of arithmetic exception handling with the -fpen flag and for_set_fpe routine. -math_library fast Specifying -math_library fast uses a fast version of certain math library routines that perform faster computations than the standard, more accurate math library routines, but with slightly less fractional accuracy and less reliable arithmetic exception handling. Using -math_library fast allows certain math library functions to get significant performance improvements when the applicable intrinsic function is used. If you specify -math_library fast, the math library routines do not necessarily check for IEEE exceptional values and the -fpen flag, and calls to the for_set_fpe routine are ignored. When you use -math_library fast, you should carefully check the calculated output from your program to verify that it is not relying on the full fractional accuracy of the floating-point data type[1] to produce correct results or producing unexpected exceptional values (exception handling is indeterminate). Programs that do not produce acceptable results with -math_library fast and single-precision data might produce acceptable results with -math_library fast if they are modified to use double-precision data. The specific intrinsic routines that have special fast math routines depend on the version of the DEC OSF/1 AXP operating system in use. Allowed error bounds vary with each routine. The math library shipped with OSF/1 AXP v3.0 and later contains special fast routines (single and double precision) for SQRT, EXP, SIN, COS, the optimized combined call SINCOS, LOG, LOG10, and power (**). ----- [1] See the DEC Fortran user manual for a description of the native IEEE floating-point data formats, including fractional precision. 2.7 IARGPTR Intrinsic and a Routine's Argument Block IARGPTR () is an intrinsic recognized by DFAO to return a pointer to the argument block of the routine in which IARGPTR is called. IARGPTR takes no arguments and returns an INTEGER*8 address of the calling-standard defined "argument block". On OpenVMS AXP and OSF/1 AXP, the address of the first actual argument is one quadword past the beginning of the "argument block". On OpenVMS AXP, the first quadword of the "argument block" is the argument count. This count is not present on OSF/1 AXP, so the contents of the first quadword of the argument block are not interesting (unless you are passing floating point values using %VAL - which is too complicated to describe here - see the Calling Standard). Here is the code example, works on both OpenVMS AXP and OSF/1 AXP: C Test IARGPTR intrinsic function. EXTERNAL test_argptr INTEGER*4 x,y,z,foo x = 10 y = 20 z = 100 foo = 4 print 800, %LOC(x), %LOC(y), %LOC(z), %LOC(foo) 800 format (' Argument addresses: ',4(1x, Z16)) CALL test_argptr (4, x, y, z, foo) END OPTIONS /EXTEND_SOURCE SUBROUTINE test_argptr (N_ARGS) POINTER (II, I_ARGN) INTEGER*8 I_ARGN POINTER (I_PTR, I_VAL) INTEGER I_VAL II = IARGPTR() ! Get address of arg block II = II + SIZEOF (II) ! Get address of address of first arg DO I = 1, N_ARGS+1 I_PTR = I_ARGN ! Get address of actual from homed ! arg list print 900, I, I_PTR, I_VAL 900 format ( ' Argument ', I2, ' address = ', Z16, ', contents = ', Z16) II = II + SIZEOF (II) ! Get address of address of next arg END DO RETURN END 2.8 DEC Fortran's Handling of Optional Arguments Fortran's language rules require that all actual and formal arguments match in number, order and type. This means that it's not allowed to omit arguments when calling a Fortran routine. Yet applications do it anyway, so we've made some accomodation for that. As long as the argument is not of type CHARACTER, or is used in an adjustable array bounds expression, you can get away with omitting arguments as long as you follow certain rules: Routines Called With Omitted Arguments Optimization for dummy arguments may cause problems for applications which contain Fortran routines that can be called with some arguments omitted. Though omission of arguments is not supported by DEC Fortran, many applications have been written which took advantage of knowledge that the compiled code did not access the argument list for dummy arguments, other than those of type CHARACTER and adjustable arrays, until the argument was actually used during execution of the routine. This assumption is not valid, and these applications may fail, typically with an segmentation fault. To disable the optimization on dummy arguments, specify the "-assume dummy_aliases" command line qualifier. An alternative is to declare the specific dummy arguments to be VOLATILE or to use them as arguments to the %LOC built-in function. (Most existing subroutines which can be called with omitted arguments use %LOC to test for a zero address; these will not require changes. However, if the test for omission is made solely on the basis of argument count or some other value, one of the above changes is necessary.) For the language requirements regarding Actual Argument and Dummy Argument Association, see the DEC Fortran Language Reference Manual. 2.9 Useful Command line Options to the f77 Driver The f77(1) man page and the DFAO User Manual gives in-depth information on all of the command line options that are available using the f77 driver. Here are some new and useful ones: o There are now cpp(1) macros defined by f77 when invoking cpp for use with conditional compilation on AXP systems. o Shared vs static libraries are created or linked with the ld(1) options "-call_shared", "-non_shared", and "-shared" available from f77. o DFAO now recognizes the "-I" command line option as a directory spec to search for INCLUDE files {just as cpp(1) uses "-I" for #include files}. You can have multiple "-I" specs on the command line. See section 5.2 below for more detail. o "-fpe" which controls floating point exception handling is now available in DFAO. The options are: -fpe0 the default: abort on overflow, divide by 0, and Invalid; return 0 on underflow -fpe1 overflow => +/-Infinity, divide by 0 => +/-Inf or NaN {0.0/0.0}, underflow => 0 -fpe2 -fpe1 semantics plus display a count of the exceptions -fpe3 overflow => +/-Infinity, divide by 0 => +/-Inf or NaN {0.0/0.0}, underflow => denorm -fpe4 -fpe3 semantics plus display a count of the exceptions Notice that exceptional behavior can result in an exceptional value, eg, overflow leads to a result of Infinity. However, exceptional values can enter a program as constants or input where they may be detected as inputs to a computation, not the result of one. In such cases, the IEEE exceptional values of +/-Infinity, NaN, and denorms are considered "invalid" data and signal an Invalid exception, which can only be handled {slowly} in -fpe modes higher than 0. See the f77(1), write_rnd(3), ieee(3), and ieee_functions(3) man pages for more information. ******** BEWARE ************************************** * Using any -fpe setting other than -fpe0 can result in * a noticeable performance slowdown. If your application * does not rely on IEEE exceptional values, remove them * and run with -fpe0. ************************************************************ || o "-fprm c | d | m | n" sets the IEEE floating point rounding mode to || chopped, normal {the default}, minus_infinity, or dynamic. See f77(1) || for more detail. See write_rnd(3) for how to set the dynamic rounding mode. o "-error_limit n" tells the compiler to stop the compilation after "n" errors. The default "n" is 30. "-noerror_limit" allows the compiler to continue no matter how many errors are reported. o "-integer_size 64" {alias "-i8"} and "-real_size 64" {alias "-r8"} can be used to increase the size of default declared data without modifying the source code. o "-automatic" forces local data to be stack-relative; "-recursive" forces all routines to be compiled for recusrsive calling; "-noautomatic" forces local data to be static, ie, allocated to memory. o "-align" has options to align or pack RECORD fields or COMMON items. "-warn alignment" {the default} points out unaligned data. Alignment is very important to high performance execution on AXP systems. "-align dcommons" aligns COMMON items on quadword boundaries; this is not the default but may be necessary for best performance. o "-convert" is used to invoke foreign file support, the ability to do unformatted I/O to big-endian or non-IEEE binary data files. Please note that format conversion does not occur on RECORD items in the I/O list {ie, those items using a STRUCTURE data declaration}. The individual fields of such RECORDs will not be converted from "foreign" to "native" format automatically by the -convert option. o "-warn" can suppress certain warnings, eg, "nounreachable", "nouninitialized", "nouncallable". o The optimization level "-On" from f77, used by the DFAO compiler, is also passed to ld to trigger certain link-time optimizations. o f77 by default assumes the main program of the application being linked is written in Fortran. If that is not the case, the "for_main.o" file linked in will cause the symbol "main" to be duplicately defined. To prevent f77 from linking in this file, use the "-nofor_main" command line option. o DFAO has the command line option: -granularity {byte | longword | quadword} defined. The default is "quadword". Use of "longword" or "byte" will cause slower performance of the generated code. o "-unroll nn" allows optimization control for loop unrolling. o "-syntax_only" requests a compile for syntax checking but won't generate object code. o f77 passes many command line options to later phases {like ld} by passing them to cc and letting cc complete the requested compilation, eg, "-D num" is passed ultimately to ld. o "-check [no]format" enables/disables some formatted I/O type checking. The default now is "-check noformat". o "-fast" means "-assume noaccuracy_sensitive -O4 -align dcommons -math_library fast" ; it is not the default. o "-warn argument_checking" {not the default} enables warnings about argument mismatches between caller and callee, when compiled together. o "-check nooutput_conversion" {the default} suppresses the OUTCONERR continuable error message. This error occurs at run time when a data item is too large to fit in a designated FORMAT descriptor field. The field is filled with asterisks (*) and execution continues. o "-warn truncated_source" {not the default} displays a warning at compile time when there are source characters to the right of column 80 (or column 132 if -extend_source) in a non-comment line. o DFAO supports profiling using -gen_feedback, -feedback , and -pg. See the DFAO User Manual for more information. 3.0 Reporting Problems with DFAO If a problem arises with the DFAO product and you report it to your support services contact inside DEC, please include a complete description of problem including o the smallest source file that reproduces the problem o the command line that compiled and linked the sources Use the "-v" option to f77. Include the version number of the compiler - it's in the listing page header. Include the what(1) strings of all libraries loaded. || o The version number of the installed Fortran RTL obtained by typing the following ls command: || % ls -l /usr/lib/cmplrs/fortrtl || This command should display the symbolic link fortrtl_36n. For example: || % ls -l /usr/lib/cmplrs/fortrtl || lrwxrwxrwx 1 root system 11 Sep 6 1255 || /usr/lib/cmplrs/fortrtl -> fortrtl_363 o any other information you think we'll need to debug the problem 4.0 Changes in previous releases of DEC Fortran for OSF/1 AXP 4.1 What Has Changed in DFAO v3.7 from DFAO v3.6 o Interesting information about DFAO v3.7 - "-speculate all" triggers the following optimization: Enables speculative code scheduling. Speculation occurs when a conditionally executed instruction is moved to a position prior to a test instruction so that the moved instruction is now executed unconditionally. This reduces instruction latency stalls although performance may be reduced because the run-time system must dismiss exceptions caused by speculative instructions. Since speculation turns off some run-time error checking this switch should not be used while debugging or while testing for errors. This optimization is only availble with AOSF v3.x and newer versions of the operating system. - DFAO v3.7 improves run-time performance for compute-bound nested loops and improves compile-time performance for large source files with many symbols. - The -vms command-line flag no longer affects alignment of data. o The following changes were made to the decfort compiler: - A recursive call to an explicitly typed ENTRY now works. - Too many externals when a listing is requested no longer causes the compiler to abort. - Fix an ACCVIO with COMMON blocks when a listing but no object file is reuqested. - The PSECT listing for a routine now ONLY includes COMMON blocks declared therein. - Fix subscripted access to pointer arrays so the code will not abort. - CDEC$PSECT ../ALIGN=n outside of a program unit used to crash decfort. - OPTIONS /ASSUME=(xxx) now appears in the listing. - Allow the passing of adjustable length character functions. - Changed default for -inline to speed. - Allow %LOC and LOC to take external names (et al) as arguments and make LOC an intrinsic. - Add "-speculate all | none" optimization. - !DEC$ directive not recognized if "!" was before column 6. - Fix default -inline based on -O: -O0/1 => none, 2/3 => manual, 4.. => speed. - Fix KIBITS (I,0,64) - 64-bit shifts were not allowed. - Recursive error flushed the rest of then statement; it now continues. - Messages that come at the end of the statement now point at the end of the statement. - Put out error message for attempting to use pointee as a function/subroutine name. - An uncalled routine with a CDEC$ ALIAS name and IMPLICIT NONE used to give an untyped name error; now it is just ignored. - Allow inline code for MVBITS and ISHFTC intrinsics. Also fix bug in IBCLR (small integers, like: -1,15). - Get character ENTRY names described correctly for the in-liner and debugger! - Get REAL*16 ENTRY names described correctly for the in-liner and debugger! - Fix -noinline on AOSF. It was ignored. - -vms no longer implies -align norecord. o The following changes were made to the f77 driver: - The driver will no longer pass "-nocount" to ld - it isn't needed. - -M also passes -P onto cpp. - DECFORT_DEBUG no longer necessary. Pass -shared onto cc, and don't add for_main.o when -shared. - Add -speculate xxx and -nospeculate. - Output usage if no files, no options passed. Error if options but no file. Also fix bug if -r8 (or similar) is specified twice. > f77 usage: "f77 [ options ] filespec [ options ]" example: "f77 foo.f -O0" or "f77 -v test2.f" > f77 -O0 fort: Severe: No source or object file specified o The following changes were made to the run-time support: - Invalid RTL, RECNUMOUT, error on REWRITE. - Unaligned record causes wrong answer to be printed - Invalid output statement overflow error generated for fixed length files when output size equaled the maximum record length - Invalid BACKSPACE error with Stream_lf file - Maximum OPEN files limit increased. - Incorrect output generated for files opened as list directed - INQUIRE name buffer overflow when using INQUIRE(name=) o The following changes to the DFAO documentation should be noted: - None for this kit. o Please note the following: - When using DECladebug on Fortran programs, please note: Parameters to an entry point go out of scope at the beginning of the next entry. It is therefore advisable to examine any parameters at the breakpoint set on the entry. Once the user steps past another ENTRY statement, DECladebug considers the program as inside that procedure and cannot reconcile the parameters to the new entry point. - The command line option "-assume dummy_aliases" affects all of the routines in a module. The OPTION statment does not support /ASSUME=DUMMY_ALIASES for individual routines. - The shell command "limit stacksize unlimited" may be used to increase the stack size used by an executing image. The semantics of "limit stacksize unlimited" is the largest value rather than unlimited. The largest value the limit stacksize command will take is 32768 which limits the stack to 2**27 bytes (4 kb /page * 2**15 page). - A change in run-time behavior affects the evaluation of "0**0". It used to be that "0**0" would return a result of 1 and no error indication. This is the semantics of the C programming language. However, now "0**0" will signal an error. The behavior can be modified slightly with "-fpe3" to allow floating point exceptional values: 0**0 default using -fpe3 at least one arg is signal returns NaN some type of Floating floating-point Invalid both args are signals returns -1 INTEGER Floating Exception - The "line number" associated with a source file diagnostic from the DFAO compiler is * an offset into the source file when the error message is displayed on the terminal * the line number from the listing file when displayed in the listing - The following changes were made to the levels at which various optimizations kick in: * while-repeat is now done at -O2 instead of -O3 * mul expansion and div expansion are now done at -O1 instead of -O2 Expansion of multiplication and division refers to bit shifts that allow faster multiplication and division while producing the same result. For example, the integer expression (I*5) can be calculated as I with a 2-bit shift plus the original value of I or, as expressed using the DEC Fortran ISHFT intrinsic function: J1 = I*5 J2 = ISHFT(I,2) + I ! equivalent expression for I*5 The optimizer uses machine code that, like the the ISHFT intrinsic function, shifts bits to expand multiplication and division. - Evaluation of REAL*16 intrinsic operations and functions at compile-time is limited to the following: + - * / real16 ** any-integer conversions to and from real16 This means that intrinsics like "QSIN (1Q400)" or operations like "1Q10 ** 1Q100" cannot appear in compile-time constant expressions like PARAMETER values and dimension declarations. 4.2 Changes from v3.5 to v3.6 of DEC Fortran for OSF/1 AXP o Interesting Information about DFAO v3.6 - "-warn unused" is now implemented {not the default}. When on, the compiler will issue warning level messages about variables that are declared but not used in a routine. - "-assume nosource_include" {not the default} tells the compiler to search the default directory for INCLUDE files {same as when "-vms" is used}. The default behavior is to search the directory the source file is in for any INCLUDEs. See also "-I" for more control over where INCLUDE files can be located. - "-tune" allows the user to select processor-specific performance tuning optimizations. The format is -tune generic | host | ev4 | ev5 Selects processor-specific instruction tuning for implementations of the Alpha AXP architecture. Regardless of the setting of the -tune option, the generated code will run correctly on all implementations of the Alpha AXP architecture. Tuning for a specific implementation can provide improvements in runtime performance; it is also possible that code tuned for a specific target may run slower on another target. generic Selects instruction tuning that is appropriate for all implementations of the Alpha AXP architecture. This option is the default. host Selects instruction tuning that is appropriate for the machine the compilation is occuring on. ev4 Selects instruction tuning for the 21064, 20164A, 21066, and 21068 implementations of the Alpha AXP architecture. ev5 Selects instruction tuning for the 21164 implementation of the Alpha AXP architecture. - "-inline" now takes "space" or "speed" to control how aggressive function in-lining is at -O4 and above. See the f77(1) man page for more information. o The following changes were made to the decfort compiler: - Fix ISNAN(constant). - Allow CHARACTER*4 A,B/'ASDF'/ to work. - Allow READ(*,1);ASSIGN 1 TO I;1 FORMAT sequence of statements. - Fix %REF(SUBSTRING_EXPRESSION) optimization. - Implement "Declared, but not used" message under "-warn unused". - New error message DAUNDEFEP is "Dummy argument is undefined at entry point ". - New error message NOEPDEFDA is "No entry point leading to this statement defines dummy argument ". - Fix weird cases for character and hex parameter constants. - Make default INCLUDE path controllable separately from "-vms", using "-assume [no]source_include". - Add "-tune" switch to select processor-specific performance tuning optimizations. - Fixed a problem with "-math_library fast" when using the REAL*16 versions of ACOS, ASIN, ATAN, ATAN2, COS, SIN, SINCOS, TAN, EXP, LOG, LOG10 and SQRT. - Dummy arguments to statement functions should ignore PARAMETERs with same name (for type information). - Add "-warn noinformational" to suppress informational warnings. - Add "-inline space" and "-inline speed". - Allow "-show nomap" to suppress symbol table map in listing. - OPTIONS summary had the wrong values for /FLOAT (and /CONVERT). - Get debugging information for BLOCK DATA programs correct. - Don't list a from an INCLUDE that's not being listed. - Allow subscripted variables as array bounds. - Allow compile-time arithmetic to be affected by "-fpe" and "-fprnd" - For conversion intrinsics, convert binary constants to INTEGER before converting to other types. - Allow !DEC$ and *DEC$ directives {ie, "!" and "*" in column 1 as well as "C"}; output better error when directive is missing - Improve memory usage and certain internal algorithms to reduce compile-time. - Get back better error message for missing ) in FORMAT statement. o The following changes were made to the f77 driver: - Make sure "-P" gets passed to whatever "cpp-like" preprocessor is used to process Fortran files, if specified by the user. o The following changes were made to the run-time support: - Bessel function bindings now exist. - ISNAN and FP_CLASS intrinsic support. - Run-time diagnostic messages now include IOSTAT number. - Colon (":") format operator fixed for implied do with zero iterations. - Improved diagnostic when catopen fails for insufficient virtual memory when opening the run-time message catalog. - PAUSE statement doesn't work properly when program is run remotely via rsh. - List-directed input does not always recognize tab characters as whitespace. - Positioning beyond end of record with nX & TRn gives incorrect record length. - X formatter at end of output format causes unpredictable behavior. - Infinitely looping format now results in an ININFFORLOO diagnostic. - Format with : descriptor and null do result n an accvio in the RTL. o The following changes to the DFAO documentation should be noted: The DEC Fortran User Manual for DEC OSF/1 AXP Systems was revised for Version 3.5. The following corrections apply: - The Fortran preprocessor environment variable DECFORT_FPP is described inaccurately. The environment variable DECFORT_FPP applies only to Fortran files (not C language files). If DECFORT_FPP is set to any value, that value must be a pathname and file name of a preprocessor to be invoked instead of cpp or fpp. The DECFORT_FPP environment variable identifies the preprocessor to be invoked if the command line requests that a preprocessor be used. Setting DECFORT_FPP to a value does not invoke a preprocessor; it is only used when the command line requests a preprocessor (cpp or fpp). For those cases where the C preprocessor cpp would have been invoked for Fortran files, if you specify the f77 flag -fpp, the Fortran preprocessor fpp is invoked instead of cpp. 4.3 Changes from v3.4 to V3.5 of DEC Fortran for OSF/1 AXP o Changes made to the decfort compiler - Change the default file types on INCLUDE to be .f, .for, .FOR. - Flag FLOATI, IMAG, IQNINT, KZEXT as non-standard intrinsic functions. - Get argument types correct for all forms of MVBITS. - Check bounds for substrings improved. - Support for -feedback, -gen_feedback, -pg. - Add error msg for no digits in octal/hex constant. - Fix error messages for array reference with too many dimensions (more than 7). - "GOTO; WRITE; ENTRY;" illegal sequence no longer aborts. - Allow more than one pointee for a pointer variable, eg, POINTER (P,A); POINTER (P,I)). - Allow recursive REAL*16 functions. - Allow recursive ENTRY points. - Allow subscripted variables in array bounds. - Allow STATIC/COMMON and STATIC/SAVE combinations of declarations. - Add -check [no]output_conversion to display/suppress the warning message when a format overflows. - Add FP_CLASS {and ISNAN} as external generic intrinsic functions. - Make IBSET with 2 small integer args (like 0,30) get the right answer. - Restore error message for COMMON block name colliding with routine name. - Include -warn usage in listing. - Improve locator in NOPATH messages. - Add -double_size n. Under -double_size 128, promote intrinsic functions, eg DCOS becomes QCOS if the argument is real*16. - Correct locator info and more warnings for "-standard semantic" and "-standard syntax"messages. - Add SELECT CASE statement: CASE, CASE DEFAULT, and ENDSELECT (see section 5.8 for details). - Get logicals right in dbx symbol table. - Get SUBSTR error (instead of range error) when appropriate. - Add EXIT/CYCLE statements and construct names on DO/ENDDO statements (see section 5.9 for details). - Add automatic arrays (see section 5.7 for details). - Allow NAMELIST variables to be SAVEd. NAMELIST always forces STATIC. - Add "-standard mia" support. - Do not allow function/entry names to be SAVEd - make them always AUTOMATIC. - Do not promote integer actual arguments unless they are constants (no expressions). - Add "-granularity " to the f77 driver. - Do not pad CDEC$ IDENT string to 31 characters: use it AS IS. - Allow REAL*16 on AOSF (see section 5.5 for details). - Show -I include path in the listing command line summary. - For block IFs and infinite DO loops, make NOPATH message point to more meaningful statements. - Add -pad_source, the CHACONCONTD message, and -warn nousage to suppress the message (see section 5.6 for details). - Fix core dump for "SUBROUTINE __x". - Make sure BYTE is always treated as INTEGER*1 (not LOGICAL*1). o The following changes were made in run-time support: - List-directed can now read a complex value into a real variable. - Fix a write error with Q edit formatter. - Improve bad FLUSH() performance. - Remove a superfluous rtl global entry point: my_for_ran_. - The G format and list-directed choice between F vs. E format now conforms to the Fortran 90 standard, which is the modified FORTRAN-77 standard definition also. - A diagnostic with a long pathname no longer gives segflt. - Improve direct, unformatted I/O performance with contiguous array slices. - DFARTL353 regression: End of file sometimes not reported correctly. - DFARTL353 regression: Superfluous rtl what strings in libraries. - RTL now scans run-time format beyond specified array element/bounds. - perror with a long string argument no longer gives unpredictable results. - perror now write to stderr rather than stdout. - Bessel function bindings now available. - IS_NAN and FP_CLASS intrinsic funtions now available. - -warn nooutput_conversion support. - Message format enhanced to include error number (IOSTAT). - Conversion of text to internal format failed to notice overflow. - List-directed IO to internal file lacked leading blank. - INQUIRE returns wrong CONVERT= values. - BIG_ENDIAN processing of INTEGER*1/LOGICAL*1 gives wrong results. - -fpe1 displays underflow messages. - Spurious chararacters in long output record. - SECNDS(SECNDS(0.0)) does not equal 0.0. - Writing large records runs out of memory and fails. - Unformatted, sequential read erroneously looks for ENDFILE marker. The non-VMS ENDFILE behavior has been changed so that files containing an ENDFILE record are now portable between Alpha/VMS and non-VMS platforms. In "VMS mode", an ENDFILE statement will write a record containing a single ^Z -- never a ^D, and never in a segment. This is what VAX Fortran does. This is the default on Alpha/VMS, and the behavior on U*x if you use -vms. In "U*x mode", an ENDFILE statement will truncate the file. This is the default on U*x, and the behavior on Alpha/VMS if you use /NOVMS. For those customers that have old segmented files with old-style ENDFILE records in them, they will have to convert their files before the RTL can read the ENDFILE records. We are assuming there are very few such customers. - Exception processing is incorrect. - -check bounds gives unknown software exception/bugcheck. - List-directed & G format set print parameters before rounding. - Access violation/segmentation fault with VFE. - Internal write with overlap produced unexpected results. - Several 3f routines use integer*8 parameters instead of integer*4. - -fpe2 and EXP function not working correctly. - srand_ causing unaligned access. - ENDDURREA with list-direct read of defaulted value at eor. - Negative unit number gives INQUIRE and OPEN problems. - MVBITS doesn't cross word/longword boundary. - LANG should be en_US.ISO8859-1. o Please note the following: - A bug in the AOSF v3.0 handling of "IEEE invalid" data may cause incorrect results when a denorm is input to an operation and the operation underflows: the result may not be set to 0.0 even if -fpe1 is used. The kernel was not signalling underflow in the case where a denormalized number represented the value exactly, only where the result was both denormalized and inexact. As a result, the part of the kernel that processed the UMZ request didn't pick up the underflow and force the zero. This will be fixed in the next release of AOSF v3.x. - Use of an uninitialized variable in a write statement is not flagged as an uninitialized variable. This will be corrected in a future release of the compiler. - "f77 -shared" tries to pass ld the "-shared" option via "cc -Wl,-shared". However, cc does not recognize "-shared" and puts the default "-call_shared" later on the ld line. Until cc is fixed, use ld directly to create shared libraries from Fortran files. - The following bugs still exist in DFAO: * The repeat count in a format statement is limited to 65535. * The 3f routines long, short, and rindex are missing. * The plot(3f) routines are not available on AOSF because the underlying plot(5) routines no longer exist on AOSF. This is a permanent restriction. - DFAO contains some support for writable shared COMMON. See the shcom_connect(3) and shcom_connect(3f) man pages (installed as part of DFA350) for the description for and examples using AOSF facilities to affect such COMMON sharing at run-time. - Note that DFAO v3.6 does not contain an updated DECladebug debugger. Use the DECladebug from the DFAO v3.5 kit or that shipped on AOSF v3.x. DECLadebug requires that 'O2ABASE' in the COBOL kit be installed. The O2ABASE subset is in DEC_Cobol_RTL/. - Once this update kit is installed, /usr/bin/f77 will invoke this version of DEC Fortran. If you wish to use a previous DEC Fortran from a subset named DFA*nnn, use the script /usr/bin/f77_nnn as a command. - The "-r16" option {also known as -real_size 128} is not in the f77(1) man page. It promotes data declared to be REAL to be REAL*16 and causes floating constants to be treated as REAL*16 {Q} constants. But it does not cause any non-generic intrinsic to automatically accept REAL*16 arguments or return REAL*16 results. - The upper limit on the length of a character constant that can be read by list-directed I/O is 2048 characters. - The math library on OSF/1 V2.0 contains a new routine: cvt_ftof (void * in, int in_type, void * out, int out_type, int flags) in_type and out_type specify the floating types as one of VAX f,d,g,h formats or ieee single or double. Currently the flags input is ignored. In subsequent releases, this routine may be enhanced to include IBM and CRAY single and double formats and options will be added to deal with source and destination endianness and the behavior on "error" cases. The prototype for cvt_ftof and the definitions of the type parameters can be found in the header file cvt.h. There is also a man page for this function. 5.0 DEC Fortran Documentation Changes 5.1 Software Pipelining (-O5) Software pipelining and additional software dependency analysis are enabled using the -O5 flag, which in certain cases improves run-time performance. As compared to regular loop unrolling (enabled at -O3 or above), software pipelining uses instruction scheduling to eliminate instruction stalls within loops, rearranging instructions between different unrolled loop iterations to improve performance. For instance, if software dependency anaylsis of data flow reveals that certain calculations can be done before or after that iteration of the unrolled loop, software pipelining reschedules those instructions ahead or behind that loop iteration at places where their execution can prevent instruction stalls or otherwise improve performance. For this version of DEC Fortran, loops chosen for software pipelining: o Are always innermost loops (those executed the most) o Do not contain branches or procedure calls o Do not use COMPLEX floating-point data (for this software version) By modifying the unrolled loop and inserting instructions as needed before and/or after the unrolled loop, software pipelining generally improves run-time performance, except for cases where the loops contain a large number of instructions with many existing overlapped operations. In this case, software pipelining may not have enough registers available to effectively improve execution performance and using -O5 instead of -O4 may not improve run-time performance. To determine whether using -O5 benefits your particular program, time program execution for the same program compiled at levels -O4 and -O5. For programs that contain loops that exhaust available registers, longer execution times may result with -O5. In cases where performance does not improve, consider compiling using -unroll 1 along with -O5 to possibly improve the effects of software pipelining. 5.2 INCLUDE file Processing with -I The compiler now supports the same INCLUDE command line switches supported by cpp(1). The compiler applies them only to Fortran INCLUDE statements of the form INCLUDE 'full-file-name' The INCLUDE command line switches specify the places the compiler should look for the file to be included, as well as the order in which those places should be searched. Search order ============ Depending on the command line switches specified the compiler searches (a) The source directory. This is the directory that contains the file that contains the INCLUDE statement; however, if the user specified -vms, it is the directory the user was in when the compiler was invoked. and/or then (b) Directories specified on the command line. and/or then (c) /usr/include Note that this is the same search order that cpp applies to a particular flavor of #include statements. Command line syntax for the compiler ==================================== Command line syntax for the compiler is -I (may be repeated for additional directories) and/or -noinclude or (default) i.e., no include-related switches Note that -I and -noinclude are not mutually exclusive. The following shows how the command line determines the search order, using the 3 "places to be searched" described above: Places to be searched Command line | (a) | (b) | (c) ===================+=======+======+======= (default) | Yes | No | Yes ===================+=======+======+======= -I | No | Yes | Yes ===================+=======+======+======= -noinclude | Yes | No | No ===================+=======+======+======= -I with -noinclude | No | Yes | No ===================+=======+======+======= Command line syntax for the driver ================================== The f77(1) driver passes -I directly to both cpp and the DFAO compiler. It passes -I (no ) to cpp, and changes it to -noinclude for the compiler. Note that on OSF/1 cpp's -I switch (with no directory) is functionally equivalent to the compiler's -noinclude switch, ie, don't look in (c). This way, the driver causes both cpp and the compiler to look for files to be included in the same places and in the same order. 5.3 Intrinsic functions promoted automatically when using -real_size 64 (-r8) With -real_size 64, there is a set of intrinsic names (listed below) that require REAL*4 or COMPLEX*8 arguments, but that often end up with REAL*8 or COMPLEX*16 arguments as the result of other work done by -real_size 64. To help avoid the need for source changes in such situations, DEC Fortran substitutes use of the equivalent intrinsic that accepts REAL*8 or COMPLEX*16 values. There is no warning/informational message when this substitution is done, since the behavior is considered intuitive. Name with argument(s) will become: ALOG REAL*8 DLOG ALOG10 REAL*8 DLOG10 AMAX1 REAL*8 DMAX1 AMIN1 REAL*8 DMIN1 AMOD REAL*8 DMOD CMPLX REAL*8 DCMPLX FLOAT REAL*8 DFLOAT IFIX REAL*8 INT REAL REAL*8 DBLE SNGL REAL*8 DBLE AIMAG COMPLEX*16 DIMAG CABS COMPLEX*16 CDABS CCOS COMPLEX*16 CDCOS CEXP COMPLEX*16 CDEXP CLOG COMPLEX*16 CDLOG CSIN COMPLEX*16 CDSIN CSQRT COMPLEX*16 CDSQRT 5.4 Version Information in .o Files DEC Fortran produces an object file that contains a variety of version number information. The response from the what utility on a DEC Fortran .o file is the string that you specify in the first CDEC$ IDENT directive. If you do not specify this directive, the what response will be empty. For more version information, enter the following command: % strings {object} | grep "@(.)" | sed "s/@([#cmd])//" This command provides information on the following .o file strings: (#)users-ident\n (may not be present) (c)compiler-ident\n (m)module-name\n (d)date\n 5.5 REAL*16 Data Type A 128-bit floating point data type is now supported by software emulation in DFAO. The data type is called "X_float" and is in an IEEE format. Its binary format is not the same as VAX "H_float" supported by VAX/VMS. All other syntax and semantics of REAL*16 from DEC Fortran on VAX/VMS as documented in the DEC Fortran Language Reference Manual are the same as for REAL*16 in DFAO. This is the same as the REAL*16 support added in DEC Fortran on AXP/VMS v6.2. The memory and register formats for X_float are strictly little- endian: +---------------------------------------------------------------+ mem | fraction_low | A +---------------------------------------------------------------+ |S| exponent | fraction_high | A+8 +---------------------------------------------------------------+ FRn v 1 FRn +---------------------------------------------------------------+ reg |S| exp | fraction_high | fraction_low | +---------------------------------------------------------------+ REAL*16 support requires the system libraries that ship with OSF/1 AXP v3.0. REAL*16 is manipulated as X_float by the foreign file support {-convert} when the file target is an IEEE format and as VAX H_float when the file target is a VAX format. In addition, two new -convert values are available: -convert fdx VAX F-float, VAX D-float, IEEE X-float -convert fgx VAX F-float, VAX G-float, IEEE X-float 5.6 -pad_source Command Line Option Spaces are insignificant in the Fortran language outside of character and Hollerith constants. The DEC Fortran compiler by default does not pad source records with explicit spaces out to the right margin {column 72 by default; 132 if -extend_source is used}. If a character or Hollerith constant is continued across record boundaries, it may not be obvious whether trailing spaces that appear to exist in fact do exist; some system editors remove trailing spaces from records. -pad_source tells the compiler to extend all source records to the current right margin with spaces to remove this potential problem. When -nopad_source is in force, a character or Hollerith literal that is continued to the next source record before the right margin will trigger a CHACONCONTD {Character Context Continued} warning. This is the first in a class of warning that can be suppressed with the "-warn nousage" command line option. {The default is "-nopad_source -warn usage".} 5.7 Automatic Arrays DFAO now supports automatic arrays: subroutine sub1(n) real a,b,c integer n dimension a(n,n),b(n,n),c(n,n) where arrays local to routines are dimensioned by variables that are dummy arguments. 5.8 The SELECT CASE Construct CASE Construct The CASE construct conditionally executes one block of constructs or statements depending on the value of a scalar expression in a SELECT CASE statement. The CASE construct takes the following form: [name :] SELECT CASE (expr) [CASE (case-value [,case-value]...) [name] block]... [CASE DEFAULT [name] block] END SELECT [name] Integer and character expressions can be expressed as a range of case values, taking one of the following forms: low:high low: :high The case expression (expr) is evaluated first. The resulting case index is compared to the case values to find a matching value (there can be at most one). When a match occurs, the block following the matching case value is executed and the construct terminates. The following rules determine whether a match occurs: o When the case value is a single value (no colon appears), a match occurs as follows: ________________________________________________________ Data_Type_________A_Match_Occurs_If:____________________ Logical case-index .EQV. case-value Integer or case-index == case-value Character_______________________________________________ o When the case value is a range of values (a colon appears), a match depends on the range specified, as follows: ________________________________________________________ Range_____________A_Match_Occurs_If:____________________ low: case-index >= low :high case-index <= high low:high__________low_<=_case-index_<=_high_____________ The following are all valid case values: CASE (1, 4, 7, 11:14, 22) ! Individual values as specified: ! 1, 4, 7, 11, 12, 13, 14, 22 CASE (:-1) ! All values less than zero CASE (0) ! Only zero CASE (1:) ! All values above zero If no match occurs but a CASE DEFAULT statement is present, the block following that statement is executed and the construct terminates. If no match occurs and no CASE DEFAULT statement is present, no block is executed, the construct terminates, and control passes to the next executable statement or construct following the END SELECT statement. Examples The following are examples of CASE constructs: INTEGER FUNCTION STATUS_CODE (I) INTEGER I CHECK_STATUS: SELECT CASE (I) CASE (:-1) STATUS_CODE = -1 CASE (0) STATUS_CODE = 0 CASE (1:) STATUS_CODE = 1 END SELECT CHECK_STATUS END FUNCTION STATUS_CODE SELECT CASE (J) CASE (1, 3:7, 9) ! Values: 1, 3, 4, 5, 6, 7, 9 CALL SUB_A CASE DEFAULT CALL SUB_B END SELECT The following three examples are equivalent: 1. SELECT CASE (ITEST .EQ. 1) CASE (.TRUE.) CALL SUB1 () CASE (.FALSE.) CALL SUB2 () END SELECT 2. SELECT CASE (ITEST) CASE DEFAULT CALL SUB2 () CASE (1) CALL SUB1 () END SELECT 3. IF (ITEST .EQ. 1) THEN CALL SUB1 () ELSE CALL SUB2 () END IF 5.9 The CYCLE and EXIT Statements and Construct Names CYCLE Statement The CYCLE statement interrupts the current execution cycle of the innermost (or named) DO construct. The CYCLE statement takes the following form: CYCLE [name] When a CYCLE statement is executed, the following occurs: 1. The current execution cycle of the named (or innermost) DO construct is terminated. If a DO construct name is specified, the CYCLE statement must be within the range of that construct. 2. The iteration count (if any) is decremented by 1. 3. The DO variable (if any) is incremented by the value of the increment parameter (if any). 4. A new iteration cycle of the DO construct begins. Any executable statements following the CYCLE statement (including a labeled terminal statement) are not executed. Examples The following example shows the CYCLE statement: DO I =1, 10 A(I) = C + D(I) IF (D(I) < 0) CYCLE ! If true, the next statement is skipped A(I) = 0 ! and the loop is tested again. END DO EXIT Statement The EXIT statement terminates a DO construct. It takes the following form: EXIT [name] When an EXIT statement is executed, the named (or innermost) DO construct is terminated. Any DO variable present retains its last defined value. Examples The following example shows an EXIT statement: LOOP_A : DO I = 1, 15 N = N + 1 IF (N > I) EXIT LOOP_A END DO LOOP_A Construct Names DO, CASE, and IF constructs can be named. The name must appear on the initial line and terminal line of the construct. In the initial line, the name is separated from the statement keyword by a colon (:). For example: [name:] SELECT CASE (expr) .... END SELECT [name] The construct name must be a unique identifier in the program unit. 5.10 Miscellaneous Functional Additions o Allow signed PARAMETERs (integer or real) in DATA statements: PARAMETER (IJK=3) ... DATA NNN /-IJK/ o Add /CONVERT, /FLOAT, and /ASSUME=[NO]BACKSLASH to the OPTIONS statement. o Add warnings for actual/formal mismatches (several) with actual being a constant of type character or real*4 (to non-character or non-real*4). o The unsupported utility fsplit was added to the DFAO kit. For more information, see the fsplit(1) man page. Note that fsplit supports source programs in fixed and free Fortran 90 format via the "-f90" and "-free" options. o The unsupported utility fpp was added to the DFAO kit. fpp is a Fortran preprocessor with a subset of the capabilities that cpp(1) has. "f77 -fpp" will invoke fpp instead of cpp on Fortran sources and process the cpp command line options that are documented as recognized in f77(1). o The intrinsics ISNAN and FP_CLASS have been added: - ISNAN(x) returns .TRUE. if x is an IEEE NaN value. "x" must be REAL or DOUBLE PRECISION. - FP_CLASS(x) returns an integer that indicates the nature of its REAL or DOUBLE PRECISION argument. /usr/include/fordef.f contains the definitions of the return value: PARAMETER FOR_K_FP_SNAN = '00000000'X PARAMETER FOR_K_FP_QNAN = '00000001'X PARAMETER FOR_K_FP_POS_INF = '00000002'X PARAMETER FOR_K_FP_NEG_INF = '00000003'X PARAMETER FOR_K_FP_POS_NORM = '00000004'X PARAMETER FOR_K_FP_NEG_NORM = '00000005'X PARAMETER FOR_K_FP_POS_DENORM = '00000006'X PARAMETER FOR_K_FP_NEG_DENORM = '00000007'X PARAMETER FOR_K_FP_POS_ZERO = '00000008'X PARAMETER FOR_K_FP_NEG_ZERO = '00000009'X o DFAO supports ampersand "&" in column 1 for continuations. o Double precision (T-floating) values are now formatted slightly differently when written with list-directed output. The exponent field has been increased from 2 to 3 characters, and the fraction field has been decreased by one character. COMPLEX values displayed by list-directed and NAMELIST writes used to begin a new record after the embedded "," if the REAL part would fit in the current record but the entire value would not. This has been fixed so that the entire value will be displayed in the next record if the entire value won't fit in this record. 6.0 DEC Fortran Documentation and Online Information Installation-related DEC Fortran documentation and the DEC Fortran subsets are available online on the media CD-ROM device (Software Product Library CD-ROM or DEC Fortran CD-ROM). Bookreader versions of the DEC Fortran documentation are provided on the Online Documentation Library CD-ROM. For more information on the contents of the Software Product Library CD-ROM or DEC Fortran CD-ROM, see the Read Before Installing or Using DEC Fortran Version 3.n for DEC OSF/1 Alpha Systems cover letter. 6.1 Online Documentation The DEC OSF/1 Software Product Library CD-ROM (media CD-ROM) kit includes a set of media CD-ROMs, a printed Software Product Library CD-ROM User's Guide (media CD-ROM user guide), and a CD-ROM "read first" letter. The media CD-ROM user guide describes the cdmenu utility and the media CD-ROM online files. With the DEC OSF/1 Software Product Library CD-ROM, see the media CD-ROM user's guide or the CD-ROM master index file to locate the correct media CD-ROM that contains the DEC Fortran directories and the names of the DEC Fortran product directories. The CD-ROM user guide and CD master index are provided as online files in the /readme directory of the first media CD-ROM. Follow the directions in the online DEC Fortran installation guide or CD-ROM user guide to mount the appropriate media CD-ROM. Use an ls command to examine the files in the DEC Fortran (/mnt/dfa380/kit and /mnt/dfa380/documentation) directories. Your media CD-ROM contains the following DEC Fortran files: o The DEC Fortran setld installation subsets o DEC Fortran documentation in PostScript[R] (.ps) form and ASCII (.txt) form, including: - The DEC Fortran installation guide - The DEC Fortran online release notes - This "read first" cover letter - The DEC Fortran Software Product Description (SPD) 6.2 Online Release Notes, Reference Pages, and Help File DEC Fortran provides the following online information, which is copied to the user's system during installation: o The DEC Fortran online release notes Provide more information on this version of DEC Fortran. You can view the DEC Fortran release notes before installing DEC Fortran once the media CD-ROM has been mounted locally from the following location: /mnt/dfa380/documentation/dfa380_relnotes.txt After installation, the online release notes are copied to: /usr/lib/cmplrs/fort/relnotes o DEC Fortran online reference pages Describe the DEC Fortran software components, including f77(1), fsplit(1), fpr(1), intro(3f), and numerous section 3f reference pages (for the 3f language interface routines) listed in intro(3f). Use the man command to read the appropriate reference page. o The DEC Fortran help file Provides online access to DEC Fortran help, which includes error message descriptions, a summary of the language elements (statements, intrinsic functions, and so on), a glossary, and other information. Use the more command or the view command to access the information available in this file, located in: /usr/lib/cmplrs/fort/decfortran.hlp The help file is large and is not usually printed on a printer or read sequentially. 6.3 Summary of the DEC Fortran Documentation Set Depending on how you order the final product, you may receive printed copies of the following DEC Fortran manuals: o DEC Fortran Language Reference Manual (AA-PU45B-TK) Revised for Version 3.7. Describes the DEC Fortran source language for reference purposes, including the format of statements, intrinsic functions, directives, and other language elements. Extensions to the ANSI FORTRAN-77 standard are identified by blue color in the printed document and by shading in Bookreader. Language differences among various DEC Fortran platforms (DEC OSF/1 AXP, Windows NT[TM] AXP, OpenVMS[TM] AXP, OpenVMS VAX[TM]) are also identified. This document is provided in Bookreader form on the Online Documentation Library CD-ROM. o DEC Fortran User Manual for DEC OSF/1 AXP Systems (AA-PW81B-TK) Last revised for Version 3.5. Describes the development and run-time environment on DEC OSF/1 AXP systems, including the f77 command and its flags, the DECladebug and dbx debuggers, run-time performance guidelines, native data characteristics, and converting unformatted files in nonnative numeric formats. It also explains DEC Fortran I/O, the language interface with C, error handling and run-time messages, using structures and records, native data characteristics, Section 3f language interface (jacket) routines, and compatibility with other products (DEC Fortran on OpenVMS VAX Systems, DEC Fortran on OpenVMS AXP Systems, and FORTRAN IV). This document is provided in Bookreader form on the Online Documentation Library CD-ROM. o DEC Fortran Installation Guide for DEC OSF/1 AXP Systems (AA-PW82B-TE) Printed version revised for Version 3.5; online CD-ROM version revised for Version 3.7. Explains how to install DEC Fortran on DEC OSF/1 AXP systems, including registering a license PAK (product authorization key), disk space and other prerequisites, and information about the DEC Fortran run-time library and message file. This installation guide is provided in PostScript form (.ps file suffix) and in plain ASCII form (.txt suffix) on the media CD-ROM; it is also provided in Bookreader form on the Online Documentation Library CD-ROM. o Read Before Installing or Using DEC Fortran Version 3.n for DEC OSF/1 Alpha Systems cover letter (AV-PW83F-TE for Version 3.8) Describes the new features of this version of DEC Fortran, provides the minimum operating system version, and other information. The letter may contain installation information and should be read before installing DEC Fortran. This cover letter is provided in PostScript form (.ps file suffix) and in plain ASCII form (.txt suffix) for the final product on the media CD-ROM. You can order the these documents in printed form from Digital as an entire kit or individually. Online help files are also provided (see Section 6.2). 6.4 Ordering Printed Documentation You can also order the printed DEC Fortran for DEC OSF/1 Alpha Systems documentation set from Digital: o DEC Fortran Language Reference Manual (AA-PU45B-TK) o DEC Fortran User Manual for DEC OSF/1 AXP Systems (AA-PW81B-TE) o DEC Fortran Installation Guide for DEC OSF/1 AXP Systems (AA-PW82B-TE) The language reference manual and read first letter were revised for Version 3.7. The online installation guide was revised for Version 3.7. To order the complete printed documentation set, specify the order number QA-MV2AA-GZ. To order printed documentation from Digital, see the "How to Order Additional Documentation" page in the back of a recently printed Digital software document or use these guidelines: o In the U.S.A., phone 1-800-344-4825 (DECdirect Sales) o In Canada, phone 1-800-267-6215 (DECdirect Sales) o In Puerto Rico, phone (809) 781-0505 o In other countries, contact your local Digital Subsidiary or reseller. 6.5 Documentation Corrections and Additions In the DEC Fortran Language Reference Manual, there are no known corrections. In the DEC Fortran User Manual for DEC OSF/1 AXP Systems, note the following corrections and additions: o The Fortran preprocessor environment variable DECFORT_FPP description is inaccurate. The environment variable DECFORT_FPP applies only to Fortran files (not C language files). If DECFORT_FPP is set to any value, that value must be a pathname and file name of a preprocessor to be invoked instead of cpp or fpp. The DECFORT_FPP environment variable identifies the preprocessor to be invoked if the command line requests that a preprocessor be used. Setting DECFORT_FPP to a value does not invoke a preprocessor; it is only used when the command line requests a preprocessor (cpp or fpp). For those cases where the C preprocessor cpp would have been invoked for Fortran files, if you specify the f77 flag -fpp, the Fortran preprocessor fpp is invoked instead of cpp. o New command-line flags and options added to DEC Fortran since Version 3.5 are not described. These new features are described elsewhere in these release notes. In the DEC Fortran Installation Guide for DEC OSF/1 AXP Systems, note the following corrections and additions in the printed version. These corrections have been fixed in the online CD-ROM version of this installation guide, but not the printed version: o The media CD-ROM pathnames and file names are now all lowercase letters. o The DEC Fortran Version 3.8 installation kit does not include a version of the DECladebug debugger. Use the version of the DECladebug debugger provided the DEC OSF/1 AXP operating system. The DEC Fortran installation guide shows installing the DECladebug debugger from the DEC Fortran kit, since the DECladebug debugger was provided with DEC Fortran Version 3.5. DEC Fortran only installs the OTABASE subset if it is newer than its equivalent library files provided with the base DEC OSF/1 AXP operating system (Version 3.0 or higher). The installation guide correctly shows the display shown when the installation of the OTABASE105 subset is being declined. Although using the command setld -i OTABASE105 might not show OTABASE105 as an installed subset, the same files usually installed by the OTABASE105 subset are already present on a DEC OSF/1 AXP Version 3.0 (or higher) system. 6.6 Sending Digital Your Comments on Documentation Digital welcomes your comments on any DEC Fortran manual or DEC Fortran online information. You can send comments to Digital in the following ways: o Internet electronic mail: fortran_docs@zko.mts.dec.com o FAX: 603-881-0120 Attn: Languages Documentation, ZKO2-3/K35 o A Reader's Comments form (located at the back of each printed DEC Fortran manual) sent to the address on the form. o A letter or card sent to the following address: Digital Equipment Corporation Languages Documentation, ZKO2-3/K35 110 Spit Brook Road Nashua, NH 03062-2698 USA [End of relnotes.]