November 30, 2005
This article was contributed by Kenneth Geisshirt
Fortran is one of the oldest programming languages. With its roots
back to the 1950s at the scientific community, the language has
evolved heavily over half a century. The evolution of Fortran reflects
the changes in the computing industry. In the 1950s computers were
programmed in machine language, and translating mathematical formulas
into machine language was indeed difficult. The system for FORmula
TRANslation was developed.
Today, Fortran is primarily used by scientists and engineers.
There is a wide variety of free and non-free scientific software
written in Fortran. A lot of the free Fortran software comes from
University professors.
Just as important, a number of
small software companies develop and sell software for limited or
specialized market segments. Examples of such software is the quantum
chemistry package
Gaussian 03
and Adina,
the Finite Element System for Structures, Heat Transfer, and CFD.
In the UNIXes of the 1980s, the most common variant of Fortran was
Fortran-77. At AT&T Bell Laboratories the free translator f2c was
developed. Translation from Fortran-77 to ISO C required a large
runtime library in order to compile the resulting C code. Later, a
front-end for GCC, the GNU C compiler (now GNU Compiler Collection) was
developed using the same runtime library.
The GNU Fortran 77 (g77) team, lead by James Craig
Burley, stopped development after it was determined that g77
was sufficient to meet the requirements of its users.
The front-end is still included in the GNU Compiler Collection
prior to version 4. It is available at the
g77 Legacy Site.
In year 2000, a new Fortran project entered the GNU scene -
GNU Fortran 95 (G95).
The goal of the G95 project is to
implement the Fortran variant or standard from 1995 (ISO/IEC
1539:1997). Currently, no bugs are known!
With the release of version 4 of GCC
in April, 2005,
Fortran 95
was included as one of the
new languages.
In GCC 4, the Fortran 95 language is fully implemented.
A valid Fortran 95 program should compile, while an invalid Fortran 95
will be rejected. GFortran uses the Tree-SSA middle of GCC, and
therefore the same back-end (or code generators) and by that, GFortran
is supported on a large number of architectures. But there exists a
number of issues with the front-end including a need for
better error messages.
Fortran has a large number of intrinsic functions. These functions are
defined in the specification of the language, they are not
implemented as a library subroutine as you might see in languages like
C and C++. Examples of Intrinsic functions include the performing of
averages of elements in an array and calculating dot products between
two vectors/arrays.
The set of I/O intrinsic functions is still limited. Most programs do
not use the advanced I/O intrinsics, and these programs will work
perfectly. Software that uses advanced I/O intrinsics might
prove to be challenging to implement.
As of this writing, a large number of free software packages can be
compiled using GFortran. Of course, most of the available packages
are related to the scientific and engineering fields.
One of the nice things about GFortran programs is that you can suspend
them during runtime. When the program receives a QUIT signal, a core
dump will be generated. Later, you can restart the program from this
core dump. This is a useful feature when your software reaches the
CPU limit, this tends to be something that is tightly
enforced in supercomputing centers around the world.
Even though the
documentation is extensive, it might not be up to date
with the latest releases of GFortran.
Most of the development in the GFortran project is focused on
implementing new intrinsics and optimizing the implementation of the
existing intrinsics.
The web pages related to GFortran are not well maintained.
If you're looking for a non-technical role in a free software
project, here's your chance to make a contribution.
(
Log in to post comments)