Fortran Compilers for Use with Source-Code GEMPACK

A suitable Fortran compiler is required for use with all Source-code versions of GEMPACK. For PCs running Windows we support these compilers:

Compiler Performance

The different compilers vary both in compile time, and in the run time of the EXE that is produced. Results are quite model-dependent. See the speed comparison table at the bottom of this page. In some cases the Intel compiler is better, but we anticipate that most users will choose GFortran.

I have Lahey already -- should I switch to GFortran?

If you have GEMPACK 11.2 or later, the answer may well be yes. If you have GEMPACK 11.0 or 11.1, the question is harder. However, this page explains how you can set up your GEMPACK to use either Lahey or GFortran -- so you can experiment to find your own preference.

Purchasing your compiler

Intel sell their Fortran compiler through various resellers and Lahey also sell through distributors and dealers. Both Lahey and Intel offer academic and multi-user pricing, and both are distributed by leading Fortran vendor Polyhedron, or, in Australia, by Devin Trussell of Computer Transition Systems. For GFortran, the free download is here.

32-bit or 64-bit?

Most PCs are running a 64-bit version of Windows; 32-bit Windows is disappearing. GEMPACK runs well on both. Both Intel Fortran and GFortran can be configured to produce either 32-bit or 64-bit EXEs. You need to make the choice at GEMPACK install time. Which should you choose ?

See also this GEMPACK-oriented comparison of 32-bit and 64-bit Windows.

Installing your Fortran

Some Releases of GEMPACK only work with specific versions of the Fortran compilers. See these pages for compiler-specific details:

You need to install and test your Fortran before you install source-code GEMPACK. See the above pages for compiler-specific instructions. In each case, we ask that you download, compile, and run a small "Hello World" program to verify your Fortran installation before installing GEMPACK.

Switching back and forth between Fortran versions with GEMPACK

Advanced users who need to do this could study these suggestions.

Non-Windows PCs

A few users run GEMPACK under Linux using the open-source GFortran compiler. See also these notes.

Compiler Performance

The following table, prepared February 2016 using GEMPACK release 11.4, compares LTG (=compile) times, and TG-program and GEMSIM run times with 4 large models. The tests were run a desktop PC running Windows 7 64-bit with a quad-core Intel i7-4770 CPU, 32 GB memory and 512 GB SSD hard drive. Compilers were: GFortran 4.8.1, Intel Fortran 14.0, Intel Fortran 16.0 and Lahey/Fujitsu Fortran 7.2 professional. Times are in seconds. The results reflect in part the various optimization settings used by GEMPACK for different compilers.

All table columns give performace of Source-code GEMPACK used with a particular compiler. The IF32 14.0 column corresponds to the distributed Executable-image version of GEMPACK, that is to say we use 32-bit Intel Fortran 14.0 to produce Executable-image GEMPACK.

fortran times
Most users will be primarily concerned with the the TG-program or GEMSIM results since they report simulation times. For Source-code users LTG compile time can be important especially during the model development cycle, however since the introduction of parallel compilation with GEMPACK 11.4, the variation in compile times is less significant than for earlier releases of GEMPACK.

Rankings are very model-dependent, but in general Intel produces faster-running EXEs. However the GF64 MMRF4 Tablo-generated program is a clear row winner while there is no significant difference between GFortran and Intel Fortran for the TERM Tablo-generated program.

See also
GFortran compiler
Intel Fortran compiler
Lahey Fortran compiler