Browse Source

Fix starpu-mpi-simgrid with simgrid 3.14

Samuel Thibault 8 years ago
parent
commit
41924f6d21
1 changed files with 8 additions and 3 deletions
  1. 8 3
      src/core/simgrid.c

+ 8 - 3
src/core/simgrid.c

@@ -823,7 +823,7 @@ typedef struct{
 	void *father_data;
 	void *father_data;
 } thread_data_t;
 } thread_data_t;
 
 
-static int _starpu_simgrid_xbt_thread_create_wrapper(int argc, char *argv[])
+static int _starpu_simgrid_xbt_thread_create_wrapper(int argc STARPU_ATTRIBUTE_UNUSED, char *argv[] STARPU_ATTRIBUTE_UNUSED)
 {
 {
 	/* FIXME: Ugly work-around for bug in simgrid: the MPI context is not properly set at MSG process startup */
 	/* FIXME: Ugly work-around for bug in simgrid: the MPI context is not properly set at MSG process startup */
 	MSG_process_sleep(0.000001);
 	MSG_process_sleep(0.000001);
@@ -846,7 +846,7 @@ static int _starpu_simgrid_xbt_thread_create_wrapper(int argc, char *argv[])
 void _starpu_simgrid_xbt_thread_create(const char *name, void_f_pvoid_t code, void *param)
 void _starpu_simgrid_xbt_thread_create(const char *name, void_f_pvoid_t code, void *param)
 {
 {
 #ifdef HAVE_SMX_ACTOR_T
 #ifdef HAVE_SMX_ACTOR_T
-	smx_actor_t process;
+	smx_actor_t process STARPU_ATTRIBUTE_UNUSED;
 #else
 #else
 	smx_process_t process;
 	smx_process_t process;
 #endif
 #endif
@@ -862,7 +862,12 @@ void _starpu_simgrid_xbt_thread_create(const char *name, void_f_pvoid_t code, vo
 #endif
 #endif
 	                         name,
 	                         name,
 	                         _starpu_simgrid_xbt_thread_create_wrapper, res,
 	                         _starpu_simgrid_xbt_thread_create_wrapper, res,
-	                         SIMIX_host_self_get_name(), -1.0, 0, NULL,
+#if SIMGRID_VERSION_MAJOR < 3 || (SIMGRID_VERSION_MAJOR == 3 && SIMGRID_VERSION_MINOR < 14)
+	                         SIMIX_host_self_get_name(),
+#else
+	                         SIMIX_host_self(),
+#endif
+				 -1.0, 0, NULL,
 	                         /*props */ NULL,0);
 	                         /*props */ NULL,0);
 }
 }
 #endif
 #endif