Compaq Visual Fortran supports extensions to the Fortran 95 and 90 ISO and ANSI standards, including a number of extensions defined by:
Compaq Fortran (including Compaq Visual Fortran) provides many of the language extensions provided by Compaq Fortran 77 for OpenVMS VAX Systems (formerly DEC Fortran 77 and VAX FORTRAN).
For information about Microsoft Fortran PowerStation 4.0, see Compatibility with Microsoft Fortran PowerStation.
This section discusses the following topics:
Compaq Visual Fortran (CVF) uses the same robust, highly efficient Fortran 95/90 compiler used by Compaq Fortran for the following Alpha operating systems:
The following table summarizes the compatibility of Compaq Visual Fortran with Compaq Fortran for Alpha systems and Compaq Fortran 77 (CF77) for OpenVMS VAX systems:
Summary of Language Compatibility
Compaq Fortran (CF) OS/Architecture Platform | |||||
---|---|---|---|---|---|
Language Feature | CVF Windows |
CF UNIX Alpha |
CF Linux Alpha |
CF OpenVMS Alpha |
CF77 OpenVMS VAX |
Linking against static and shared libraries | X | X | X | X | X |
Create code for shared libraries | X | X | X | X | X |
Recursive code support | X | X | X | X | X |
AUTOMATIC and STATIC statements | X | X | X | X | X |
STRUCTURE and RECORD declarations | X | X | X | X | X |
INTEGER*1, *2, *4 | X | X | X | X | X |
LOGICAL*1, *2, *4 | X | X | X | X | X |
INTEGER*8 and LOGICAL*8 | X | X | X | X | |
REAL*4, *8 | X | X | X | X | X |
REAL*161 | X | X | X | X | |
COMPLEX*8, *16 | X | X | X | X | X |
COMPLEX*322 | X | X | X | ||
POINTER (CRAY-style) | X | X | X | X | X |
INCLUDE statement | X | X | X | X | X |
IMPLICIT NONE statement | X | X | X | X | X |
Data initialization in type declarations | X | X | X | X | X |
Automatic arrays | X | X | X | X | |
VOLATILE statements | X | X | X | X | X |
NAMELIST-directed I/O | X | X | X | X | X |
31-character names including $ and _ | X | X | X | X | X |
Source listing with machine code | X | X | X | X | X |
Debug statements in source | X | X | X | X | X |
Bit constants to initialize data and use in arithmetic | X | X | X | X | X |
DO WHILE and END DO statements | X | X | X | X | X |
Built-in functions %LOC, %REF, %VAL | X | X | X | X | X |
SELECT CASE construct | X | X | X | X | |
EXIT and CYCLE statements | X | X | X | X | |
Variable FORMAT expressions (VFEs) | X | X | X | X | X |
! marks end-of-line comment | X | X | X | X | X |
Optional run-time bounds checking for arrays and substrings | X | X | X | X | X |
Binary (unformatted) I/O in IEEE big endian, IEEE little endian, VAX, IBM, and CRAY floating-point formats | X | X | X | X | X |
Fortran 95/90 standards checking | X | X | X | X | |
FORTRAN-77 standards checking | X | ||||
IEEE exception handling | X | X | X | X | |
VAX floating data type in memory | X | X | |||
IEEE floating data type in memory | X | X | X | X | |
CDD/Repository DICTIONARY support | X | ||||
KEYED access and INDEXED files | X | X | |||
Parallel decomposition | 4 | X3,4 | 4 | X | |
OpenMP parallel directives | X | ||||
Conditional compilation using IF...DEF constructs | X | X | X | X | |
Vector code support | X | ||||
Direct inlining of Basic Linear Algebra Subroutines (BLAS) | 5 | 5 | 5 | 5 | X |
DATE_AND_TIME returns 4-digit year | X | X | X | X | X |
FORALL statement and construct | X | X | X | X | |
Automatic deallocation of ALLOCATABLE arrays | X | X | X | X | |
Dim argument to MAXLOC and MINLOC | X | X | X | X | |
PURE user-defined subprograms | X | X | X | X | |
ELEMENTAL user-defined subprograms | X | X | X | X | |
Pointer initialization (initial value) | X | X | X | X | |
The NULL intrinsic to nullify a pointer | X | X | X | X | |
Derived-type structure initialization | X | X | X | X | |
CPU_TIME intrinsic subroutine | X | X | X | X | |
Kind argument to CEILING and FLOOR intrinsics | X | X | X | X | |
Nested WHERE constructs, masked ELSEWHERE statement, and named WHERE constructs | X | X | X | X | |
Comments allowed in namelist input | X | X | X | X | |
Generic identifier in END INTERFACE statements | X | X | X | X | |
Minimal FORMAT edit descriptor field width | X | X | X | X | |
Detection of Obsolescent and/or Deleted features6 | X | X | X | X |
Footnotes to preceding table:
1 | For REAL*16 data, OpenVMS VAX systems use H_float format, and Alpha systems use IEEE style X_float format. |
2 | For COMPLEX*32 data, Alpha systems use IEEE style X_float format for both REAL*16 parts. |
3 | For parallel processing with Compaq Fortran for Compaq Tru64 UNIX Systems, you can use the OpenMP or Compaq Fortran directives on shared memory multiprocessor systems or MPI software for using High Performance Fortran (HPF) constructs across multiple systems. |
4 | For parallel processing, you can use the optional KAP performance preprocessor for a shared memory multiprocessor system. |
5 | BLAS and other routines are available with the Compaq Extended Mathematical Library (CXML) software provided with Compaq Visual Fortran and Compaq Fortran for Alpha systems (for download information, see http://www.compaq.com/math). |
6 | Compaq Fortran flags these deleted and obsolescent features, but fully supports them. |
To simplify porting applications between Compaq Fortran 77 Alpha systems and Compaq Fortran (including Compaq Visual Fortran), Compaq Visual Fortran supports the following Compaq Fortran 77 extensions that are not part of the Fortran 95/90 standards:
In addition to language extensions, Compaq Visual Fortran also supports the following Compaq Fortran 77 features:
Compaq Visual Fortran includes the following features and enhancements also found on other Compaq Fortran platforms:
Major additions and improvements to the FORTRAN 77 standard introduced by the Fortran 90 standard include:
In addition, the Fortran 90 standard includes the following industry-accepted extensions to the FORTRAN 77 standard:
Major changes and improvements to the Fortran 90 standard introduced by the Fortran 95 standard include:
For more information:
When porting code between platforms, be aware that:
Character arguments on OpenVMS systems may be passed by character descriptors not found on other platforms.
For more details about the OpenVMS Alpha programming environment, see the appropriate sections in the Compaq Fortran User Manual for OpenVMS Alpha Systems.
Certain platform-specific Fortran routine names either have QQ appended at the end of the name or use the Win32 naming conventions (see Calling Win32 Routines). Certain groups of routines require different USE statements. You can use the HTML Help viewer's index and search facility to locate descriptions of Visual Fortran or Win32 routines.
The online Visual Fortran Language Reference and the printed Compaq Fortran Language Reference Manual identify language elements that are supported only on certain Compaq Fortran platforms.
ftp
for binary file transfers to preserve file
integrity. Visual Fortran provides the capability to convert unformatted data files in
various formats, including big endian formats (see Supported
Native and Nonnative Numeric Formats). It is also important to
select compatible cross-platform record types.
When porting data files between Windows systems running Compaq Visual Fortran and Alpha systems running Compaq Fortran:
One suggested way to port an unformatted file from an OpenVMS system follows:
$ SET FILE /ATTR=(RFM=FIX,LRL=512) file.dat
For information on porting unformatted data files, see the Compaq Fortran Knowledge Base
at http://www.compaq.com/fortran/kb.
Examples of record type conversion programs are available at
http://www.compaq.com/fortran/examples.RECORDTYPE='SEGMEMTED'
.For more information: