Intel® Fortran Compiler - Support for Fortran language standards

Submit New Article

Last Modified On :   June 24, 2009 12:41 PM PDT
Rate
 


Intel® Fortran is fully compliant with the ISO/IEC 1539:1997 Fortran language standard (Fortran 95). Intel Fortran also fully supports programs that conform to the earlier standards Fortran 90, FORTRAN 77 and FORTRAN IV (FORTRAN 66.) In some cases, compiler options may need to be specified to enable support of behavior that was different in earlier versions of the Fortran standard.

The Intel Fortran compiler supports many features that are new to the latest revision of the Fortran standard, Fortran 2003 (ISO/IEC 1539:2004 ). Additional Fortran 2003 features will appear in future versions. Fortran 2003 features supported by the version 11.1 compiler include:

  • The Fortran character set has been extended to contain the 8-bit ASCII characters ~ [ ] ` ^ { } | # @
  • Names of length up to 63 characters
  • Statements of up to 256 lines
  • Square brackets [ ] are permitted to delimit array constructors instead of (/ /)
  • Structure constructors with component names and default initialization
  • Array constructors with type and character length specifications
  • A named PARAMETER constant may be part of a complex constant
  • Enumerators
  • Allocatable components of derived types
  • Allocatable scalar variables
  • Deferred-length character entities
  • PUBLIC types with PRIVATE components and PRIVATE types with PUBLIC components
  • ERRMSG keyword for ALLOCATE and DEALLOCATE
  • SOURCE= keyword for ALLOCATE
  • Type extension
  • CLASS declaration
  • Polymorphic entities
  • Inheritance association
  • Deferred bindings and abstract types
  • Type-bound procedures
  • TYPE CONTAINS declaration
  • ABSTRACT attribute
  • DEFERRED attribute
  • NON_OVERRIDABLE attribute
  • ASYNCHRONOUS attribute and statement
  • BIND(C) attribute and statement
  • PROTECTED attribute and statement
  • VALUE attribute and statement
  • VOLATILE attribute and statement
  • INTENT attribute for pointer objects
  • Reallocation of allocatable variables on the left hand side of an assignment statement when the right hand side differs in shape or length (requires option "assume realloc_lhs")
  • ASSOCIATE construct
  • SELECT TYPE construct
  • In all I/O statements, the following numeric values can be of any kind: UNIT=, IOSTAT=
  • NAMELIST I/O is permitted on an internal file
  • Restrictions on entities in a NAMELIST group are relaxed
  • FLUSH statement
  • WAIT statement
  • ACCESS='STREAM' keyword for OPEN
  • ASYNCHRONOUS keyword for OPEN and data transfer statements
  • ID keyword for INQUIRE and data transfer statements
  • POS keyword for data transfer statements
  • PENDING keyword for INQUIRE
  • The following OPEN numeric values can be of any kind: RECL=
  • The following READ and WRITE numeric values can be of any kind: REC=, SIZE=
  • The following INQUIRE numeric values can be of any kind: NEXTREC=, NUMBER=, RECL=, SIZE=
  • Recursive I/O is allowed in the case where the new I/O being started is internal I/O that does not modify any internal file other than its own
  • IEEE Infinities and NaNs are displayed by formatted output as specified by Fortran 2003
  • BLANK, DELIM, ENCODING, IOMSG, PAD, ROUND, SIGN, SIZE I/O keywords
  • DC, DP, RD, RC, RN, RP, RU, RZ format edit descriptors
  • In an I/O format, the comma after a P edit descriptor is optional when followed by a repeat specifier
  • Rename of user-defined operators in USE
  • INTRINSIC and NON_INTRINSIC keywords in USE
  • IMPORT statement
  • Allocatable dummy arguments
  • Allocatable function results
  • PROCEDURE declaration
  • Procedure pointers
  • ABSTRACT INTERFACE
  • PASS and NOPASS attributes
  • Execution of a STOP statement displays a warning if an IEEE floating point exception is signaling
  • The COUNT_RATE argument to the SYSTEM_CLOCK intrinsic may be a REAL of any kind
  • COMMAND_ARGUMENT_COUNT intrinsic
  • GET_COMMAND intrinsic
  • GET_COMMAND_ARGUMENT intrinsic
  • GET_ENVIRONMENT_VARIABLE intrinsic
  • IS_IOSTAT_ END intrinsic
  • IS_IOSTAT_EOR intrinsic
  • MAX/MIN/MAXVAL/MINVAL/MAXLOC/MINLOC intrinsics allow CHARACTER arguments
  • MAXLOC or MINLOC of a zero-sized array returns zero (requires option "assume noold_maxminloc")
  • MOVE_ALLOC intrinsic
  • NEW_LINE intrinsic
  • SELECTED_CHAR_KIND intrinsic
  • The following intrinsics take an optional KIND= argument: ACHAR, COUNT, IACHAR, ICHAR, INDEX, LBOUND, LEN, LEN_TRIM, MAXLOC, MINLOC, SCAN, SHAPE, SIZE, UBOUND, VERIFY
  • Type inquiry intrinsic functions
  • ISO_C_BINDING intrinsic module
  • IEEE_EXCEPTIONS, IEEE_ARITHMETIC and IEEE_FEATURES intrinsic modules
  • ISO_FORTRAN_ENV intrinsic module

Please see the compiler release notes for an updated list.

The Intel Fortran compiler also supports some features from the draft Fortran 2008 standard. These include:

  • Passing internal procedures as actual arguments
  • A procedure pointer can point to an internal procedure
  • In ALLOCATE, if source-object does not have a shape specified, the shape is taken from the SOURCE= argument

Intel Fortran also includes a number of extensions to Fortran 2003, as well as command-line options that allow you to override the default actions of the compiler.

In some cases, the default behavior of the Intel Fortran Compiler does not conform to Fortran 2003 semantics.  The following table lists the compiler options which are not enabled by default and which must be specified to obtain full Fortran 2003 semantics. Note that, in some cases, enabling these options may lower run-time performance.

Non-Default Compiler Options for Fortran 2003 Semantics
Windows* Linux* and Mac OS X*
/assume:byterecl -assume byterecl
/assume:minus0 -assume minus0
/assume:noold_maxminloc -assume noold_maxminloc
/assume:noold_unit_star -assume noold_unit_star
/assume:noold_xor -assume noold_xor
/assume:protect_parens -assume protect_parens
/assume:realloc_lhs -assume realloc_lhs
/assume:std_mod_proc_name -assume std_mod_proc_name

 

For more information, please refer to the "Compiler Options" section of the Intel Fortran Compiler documentation.





This article applies to: Intel® Fortran Compiler for Linux* Knowledge Base,   Intel® Fortran Compiler for Mac OS X* Knowledge Base,   Intel® Visual Fortran Compiler for Windows* Knowledge Base