Newsgroups: comp.parallel.mpi
From: hleroy@irisa.fr (Hugues Leroy)
Subject: MPI Timing on Ibm SP2
Organization: Irisa, Rennes (FR)
Date: 19 May 1996 22:04:50 GMT
Message-ID: <4no5u2$lkh@news.irisa.fr>

Hi,
What is the most appropriate routine to mesure elapsed time on Ibm Sp2 ?
As MPI_WTIME() is for wall clock time, let's try mclock() and etime()
on the following example:

Prog A (on 1 Cpu : as cpu==1 don't do any msg passing)

	Integer T1,T2
	Real*4 TT1,TT2,T(2)
	T1=mclock()
	TT1=ETIME(T)
	do .... some sequential work
	T2=mclock()
	TT2=ETIME(T)
	print *,'timing results:',float(T2-T1)/100
	print *,' or :',TT2-TT1

results are quite the same (say: 512.16 and 512.26)


Prog A (MPI on 3 cpus)
======================

	Real*4 TT1,TT2,T(2)
	T1=mclock()
	TT1=ETIME(T)
	do ... some work AND MPI message passing
	T2=mclock()
	TT2=ETIME(T)
	print *,'timing results:',float(T2-T1)/100
	print *,' or :',TT2-TT1

Results here differs !
                    mclock/100   etime:
timing for proc 1:  312.03       778.55 
timing for proc 2:  232.76       314.44
timing for proc 3:  304.22       882.25
wall clock: 15:03.34


So, why do this results differs ? which one should i use ?
PS: on an Intel Paragon, for the same application, dclock() and
etime() results are quite equivalent ...

Thanks for any light

-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Hugues Leroy  INRIA /IRISA 35042 RENNES CEDEX, FRANCE
        http://www.irisa.fr/rapid
Tel: (+33) 99 84 74 17         Fax: (+33) 99 84 71 71
==-=--=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=


