Explorar o código

Fix build with simgrid 3.13

Samuel Thibault %!s(int64=8) %!d(string=hai) anos
pai
achega
83465cc907
Modificáronse 1 ficheiros con 8 adicións e 0 borrados
  1. 8 0
      src/core/simgrid.c

+ 8 - 0
src/core/simgrid.c

@@ -1013,7 +1013,11 @@ static int _starpu_simgrid_xbt_thread_create_wrapper(int argc STARPU_ATTRIBUTE_U
 	smx_process_t
 #endif
 	self = SIMIX_process_self();
+#if SIMGRID_VERSION_MAJOR < 3 || (SIMGRID_VERSION_MAJOR == 3 && SIMGRID_VERSION_MINOR < 14)
+	thread_data_t *t = SIMIX_process_self_get_data();
+#else
 	thread_data_t *t = SIMIX_process_self_get_data(self);
+#endif
 	simcall_process_set_data(self, t->father_data);
 	t->code(t->userparam);
 	simcall_process_set_data(self, NULL);
@@ -1033,7 +1037,11 @@ void _starpu_simgrid_xbt_thread_create(const char *name, void_f_pvoid_t code, vo
 	_STARPU_MALLOC(res, sizeof(thread_data_t));
 	res->userparam = param;
 	res->code = code;
+#if SIMGRID_VERSION_MAJOR < 3 || (SIMGRID_VERSION_MAJOR == 3 && SIMGRID_VERSION_MINOR < 14)
+	res->father_data = SIMIX_process_self_get_data();
+#else
 	res->father_data = SIMIX_process_self_get_data(SIMIX_process_self());
+#endif
 
 #if SIMGRID_VERSION_MAJOR < 3 || (SIMGRID_VERSION_MAJOR == 3 && SIMGRID_VERSION_MINOR < 12)
 	simcall_process_create(&process,