X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/233c22349336937a5ddfef86eddcbe3bb78bb801..806d1314d9398af51ffd016c95b39d173960c659:/include/smpi/smpif.h.in diff --git a/include/smpi/smpif.h.in b/include/smpi/smpif.h.in index b8d3ccdf84..3e8ddf7b73 100644 --- a/include/smpi/smpif.h.in +++ b/include/smpi/smpif.h.in @@ -7,19 +7,39 @@ #ifndef SMPIF_H #define SMPIF_H -#cmakedefine HAVE_SMPI_F2C_H @HAVE_SMPI_F2C_H@ +#cmakedefine HAVE_F2C_H @HAVE_SMPI_F2C_H@ -#ifdef HAVE_SMPI_F2C_H - #undef min //Need because first def in xbt.h - #undef max //Need because first def in xbt.h - #include +#ifndef HAVE_F2C_H +#error F2C is mandatory #endif #include +#include +#include XBT_PUBLIC(int) smpi_process_argc(void); XBT_PUBLIC(int) smpi_process_getarg(integer* index, char* dst, ftnlen len); -XBT_PUBLIC(int) smpi_global_rank(void); XBT_PUBLIC(int) smpi_global_size(void); +#define smpi_sample_local__(pi,pt) \ + { \ + if(smpi_sample_1(0, __FILE__, __LINE__, *pi, *pt)) { \ + smpi_sample_3(0, __FILE__, __LINE__); \ + } \ + if(!smpi_sample_2(0, __FILE__, __LINE__)) { \ + continue; \ + } \ + } + +#define smpi_sample_global__(pi,pt) \ + { \ + if(smpi_sample_1(1, __FILE__, __LINE__, *pi, *pt)) { \ + smpi_sample_3(1, __FILE__, __LINE__); \ + } \ + if(!smpi_sample_2(1, __FILE__, __LINE__)) { \ + continue; \ + } \ + } + + #endif