From: mstillwell Date: Thu, 24 Nov 2011 15:15:22 +0000 (+0100) Subject: gettimeofday also needs to update benchmark info. X-Git-Tag: exp_20120216~195^2~19^2 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/328643cc32ac0aa81f4bec9eff7953458f128fc5 gettimeofday also needs to update benchmark info. --- diff --git a/include/smpi/smpi.h b/include/smpi/smpi.h index a104544a73..962b1349aa 100644 --- a/include/smpi/smpi.h +++ b/include/smpi/smpi.h @@ -71,6 +71,7 @@ typedef struct { } MPI_Status; #define MPI_STATUS_IGNORE NULL +#define MPI_STATUSES_IGNORE NULL #define MPI_DATATYPE_NULL NULL extern MPI_Datatype MPI_CHAR; diff --git a/src/smpi/smpi_bench.c b/src/smpi/smpi_bench.c index a6e7b631d5..6cad02ee91 100644 --- a/src/smpi/smpi_bench.c +++ b/src/smpi/smpi_bench.c @@ -177,11 +177,14 @@ unsigned int smpi_sleep(unsigned int secs) int smpi_gettimeofday(struct timeval *tv, struct timezone *tz) { - double now = SIMIX_get_clock(); + double now; + smpi_bench_end(); + now = SIMIX_get_clock(); if (tv) { - tv->tv_sec = (time_t) now; + tv->tv_sec = (time_t)now; tv->tv_usec = (suseconds_t)((now - tv->tv_sec) * 1e6); } + smpi_bench_begin(); return 0; }