X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/a846b9415542cdaa8ba5d0f7efeadecb56ba7c2c..c6d533c9cc016b1efb935af6b8407a94f3e65a30:/examples/msg/actions/actions.c diff --git a/examples/msg/actions/actions.c b/examples/msg/actions/actions.c index 758ebf111e..a45db1fd84 100644 --- a/examples/msg/actions/actions.c +++ b/examples/msg/actions/actions.c @@ -11,8 +11,6 @@ #include "xbt.h" /* calloc, printf */ #include "instr/instr_private.h" -void SIMIX_ctx_raw_factory_init(smx_context_factory_t *factory); - XBT_LOG_NEW_DEFAULT_CATEGORY(actions, "Messages specific for this msg example"); int communicator_size = 0; @@ -38,7 +36,7 @@ static double parse_double(const char *string) value = strtod(string, &endptr); if (*endptr != '\0') - THROW1(unknown_error, 0, "%s is not a double", string); + THROWF(unknown_error, 0, "%s is not a double", string); return value; } @@ -198,7 +196,7 @@ static void action_wait(const char *const *action) double clock = MSG_get_clock(); process_globals_t globals = (process_globals_t) MSG_process_get_data(MSG_process_self()); - xbt_assert1(xbt_dynar_length(globals->irecvs), + xbt_assert(xbt_dynar_length(globals->irecvs), "action wait not preceded by any irecv: %s", xbt_str_join_array(action," ")); if (XBT_LOG_ISENABLED(actions, xbt_log_priority_verbose)) @@ -281,7 +279,7 @@ static void action_reduce(const char *const *action) process_globals_t counters = (process_globals_t) MSG_process_get_data(MSG_process_self()); - xbt_assert0(communicator_size, "Size of Communicator is not defined, " + xbt_assert(communicator_size, "Size of Communicator is not defined, " "can't use collective operations"); process_name = MSG_process_get_name(MSG_process_self()); @@ -334,7 +332,7 @@ static void action_bcast(const char *const *action) process_globals_t counters = (process_globals_t) MSG_process_get_data(MSG_process_self()); - xbt_assert0(communicator_size, "Size of Communicator is not defined, " + xbt_assert(communicator_size, "Size of Communicator is not defined, " "can't use collective operations"); process_name = MSG_process_get_name(MSG_process_self()); @@ -401,7 +399,7 @@ static void action_allReduce(const char *const *action) { process_globals_t counters = (process_globals_t) MSG_process_get_data(MSG_process_self()); - xbt_assert0(communicator_size, "Size of Communicator is not defined, " + xbt_assert(communicator_size, "Size of Communicator is not defined, " "can't use collective operations"); process_name = MSG_process_get_name(MSG_process_self()); @@ -525,8 +523,6 @@ int main(int argc, char *argv[]) { MSG_error_t res = MSG_OK; - smx_factory_initializer_to_use = SIMIX_ctx_raw_factory_init; - /* Check the given arguments */ MSG_global_init(&argc, argv); if (argc < 3) {