>I would like to get your opinion about the difference in speed between the
>following two options and why do you prefer one over the other.
No difference. Why would you expect one? Fortran demands that the limit
expression of a DO loop is evaluated exactly one, so a compiler would need
to be a "pessimising" compiler to notice that the expression had no side
effects and so could be evaluated multiple times without affecting the
semantics! I am not aware of any such compilers...
Cheers,
--
...........................Malcolm Cohen, NAG Ltd., Oxford, U.K.
([log in to unmask])
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|