Re: MODULEand USE versus Argument Passing



"Herman D. Knoble" wrote:
>
> Given a Subprogram that gets called millions of times,
> we know that there is (CPU) overhead for subprogram linkage.
>
> My question is, independent of compilers, which is more efficient
> in practice:
>
> passing a list of (say 3 to 10) arguments to a subprogram's
> corresponding parameters,
> OR using a Module and companion USE statement,
> OR use named COMMON?

If by (b) you mean the variables which would otherwise be in the
argument list, I see no reason there would be any difference between (b)
and (c). (a) would entail some level of overhead.

How much it affects a given routine would be pretty easy to time for a
specific example.
.



Relevant Pages

  • MODULEand USE versus Argument Passing
    ... we know that there is (CPU) overhead for subprogram linkage. ... My question is, independent of compilers, which is more efficient ...
    (comp.lang.fortran)
  • Re: rewrite glRotate?
    ... computation easily outperforms the call overhead of OpenGL ... Nowadays CPU have multiparallel pipelines, ... are highly parallel and execute things out of order. ...
    (comp.graphics.api.opengl)
  • RE: Whats a CPU second?
    ... You have in fact hit upon the fundamental problem here: ... If a job uses 1.00 CPU seconds on a one CP x 100 MSU box, ... I understand the concept of MP overhead perfectly. ... Of Craddock, Chris ...
    (bit.listserv.ibm-main)
  • Re: Scheduler fairness problem on 2.6 series
    ... I am working on a load balancing class using mpi. ... |> tested) cluster overhead is just as low as 3% to 5%, ... Or that the cpu is ... just for making it clear and final communication:) ...
    (Linux-Kernel)
  • Re: SuSE thinks I have two cpus (sorry I only have one)
    ... > PLUS the overhead needed for the emulation to exist. ... > to schedule tasks in the best possible way for 1 cpu. ... is diminshed to 0 but your processing power is still way above a single processor. ...
    (alt.os.linux.suse)