Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
fix tests with timers by properly detecting POSIX_TIMERS
[simgrid.git] / include / smpi / smpi_helpers.h
1 #ifndef MPI_HELPERS_H
2 #define MPI_HELPERS_H
3
4 #include <unistd.h>
5 #include <sys/time.h> /* Load it before the define next line to not mess with the system headers */
6
7 #define sleep(x) smpi_sleep(x)
8 #define usleep(x) smpi_usleep(x)
9 #define gettimeofday(x, y) smpi_gettimeofday(x, 0)
10 #if _POSIX_TIMERS > 0
11 #define nanosleep(x, y) smpi_nanosleep(x, y)
12 #define clock_gettime(x, y) smpi_clock_gettime(x, y)
13 #endif
14
15 #define getopt(x,y,z) smpi_getopt(x,y,z)
16 #define getopt_long(x,y,z,a,b) smpi_getopt_long(x,y,z,a,b)
17
18 #endif