fortran in linux

 
SOLVED
Go to solution
Ouri David
Frequent Advisor

fortran in linux

I have a very large fortran program.Many
variables are not inialized at the start of
the program.HP & IBM fortran in unix assume
that undeclared variables are zero.
Is there a flag I can set do overcome the
problem in Linux.

Thanking You
o.david
david
4 REPLIES 4
Dave Kelly_1
Respected Contributor
Solution

Re: fortran in linux

The flag is -finit-local-zero
Ouri David
Frequent Advisor

Re: fortran in linux

thanks it soved our problem
david
Ouri David
Frequent Advisor

Re: fortran in linux

the option -finit-local-zero solved one
problem but did not solve the below:
a subroutine that is called many times had
the undecaled variable set to zero on each
entry to the subroutine instead of entering
with the last value it had on return from
the subroutine.
what is needed is a once only zero initialization.
Can you help ??
Thank You
david
Dave Kelly_1
Respected Contributor

Re: fortran in linux

If you are talking about SAVEing across procedure calls, you could try the flag

-fno-automatic