Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

compile as f77?

laura_s_kang
Beginner
797 Views
I have some old fortran codes in f77. When I compile them in Intel Visual Fortran, it's compiled, but results are not quite right. Is there any option in the property I can select to compile filesas f77?
Thanks,
Laura
0 Kudos
4 Replies
TimP
Honored Contributor III
797 Views
ifort has a bunch of options to match specific features of past f77 compilers. Most of them don't pertain to differences between f77 and f90. Certain compilers which had the equivalent of -Qsave and -Qzero as defaults. The behavior implicit in /fpconstant was permitted as a default in f77, but not f90. If the program was written for a machine which had a high default precision, /Qautodouble might be appropriate. /fltconsistency requires stricter compliance with the Fortran standard on parentheses, and has other effects besides.
0 Kudos
Steven_L_Intel1
Employee
797 Views
A correct F77 program should not have any differences, but many programs make assumptions that aren't valid in F90. Tim mentioned the big one which affects code such as:

DOUBLE PRECISION PI
PI = 3.1415926535897

That value is single precision, but many F77 compilers carried it in higher precision for the assignment. F90 doesn't allow that. /fpconstant gets the nonstandard behavior.

There really aren't any SAVE differences worth mentioning.
0 Kudos
madhu_iitc
Beginner
797 Views
I am having a problem running F 77 code on intel 7.1 compiler for windows. I tried running it on microsoft V NET and also on the DOS prompt. even then i am getting lot of errors.
the compile command i used is : ifl -FI filename.
any suggestions will be appreciated,
thank you,
cheers
Madhu
0 Kudos
Steven_L_Intel1
Employee
797 Views
What are the errors? What is the actual filename?
0 Kudos
Reply