LAM/MPI logo

LAM/MPI General User's Mailing List Archives

  |   Home   |   Download   |   Documentation   |   FAQ   |   all just in this list

From: Jeff Squyres (jsquyres_at_[hidden])
Date: 2003-07-11 06:29:56


On Wed, 9 Jul 2003, Sherif Abd El-Momen wrote:

> I am trying to measure the performance of my application. I am using
> linux function "times"to give me the exact clock ticks used by my
> process. when I used the same method to measure,the time for
> communication " I am using MPI_Ssend" the result was zero. I aslo tried
> to measure the system time for the communication - tms.stime- it also
> returnd zero. is it because the process was blocked.

Yes, there may be blocking involved which may or may not accurately be
recorded in the system timers. Generally, we use wall-clock time on
otherwise unloaded machines/networks as the best measure of
performance.

> I am using this way of measuring to ignore the os overhead. please
> advice if there is a better way that I can use.

Totally eliminating the OS overhead is pretty hard to do, especially
because it can be so variable. For LAM tracing purposes, we generally
just look at the wall clock time at various places and manually calculate
system time vs. user time, etc. For example, something like the
following:

        int MPI_Send(...) {
          user_t1 = MPI_Wtime();
          ...
          system_t1 = MPI_Wtime();
          write(...)
          system_t2 = MPI_Wtime();
          ...
          user_t2 = MPI_Wtime();
        }

Then you can do the subtraction to approximate system vs. user time,
etc.

I realize that this doesn't help you in a user application. :-(

-- 
{+} Jeff Squyres
{+} jsquyres_at_[hidden]
{+} http://www.lam-mpi.org/