Re: MODULEand USE versus Argument Passing
*** Hendrickson wrote:
(snip comparing subroutine arguments, module variables,
and COMMON)
Seriously, I think the answer is none of the above, it's
"whatever makes the most sense to you". If the subroutine
does anything significant, then the call overhead is
likely to be small either way, and if the subroutine is
small (for some definition of small ;) ), turn on inlining
and let the compiler figure it out.
Yes, I agree.
There are a few places where small changes can make a big
difference in runtime, but this isn't (usually) one.
One is the order of loops going through multidimensional
arrays. Not at all obvious looking at the code, though.
The one related to arguments is when an array copy needs to
be make of a large array, though only small use is made of the
array.
-- glen
.