X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/0ca1291c2f63ca6235f4b4885c48413a900aade4..08ce0edd12b2c42378cc228a91d37613bbc2acbc:/src/simix/smx_host.c diff --git a/src/simix/smx_host.c b/src/simix/smx_host.c index c1d3e0ccd5..7eac4a4739 100644 --- a/src/simix/smx_host.c +++ b/src/simix/smx_host.c @@ -209,10 +209,6 @@ smx_action_t SIMIX_host_execute(const char *name, smx_host_t host, surf_workstation_model->set_priority(action->execution.surf_exec, priority); } -#ifdef HAVE_TRACING - TRACE_smx_host_execute(action); -#endif - XBT_DEBUG("Create execute action %p", action); return action; @@ -267,9 +263,6 @@ void SIMIX_host_execution_destroy(smx_action_t action) action->execution.surf_exec = NULL; } -#ifdef HAVE_TRACING - TRACE_smx_action_destroy(action); -#endif xbt_mallocator_release(simix_global->action_mallocator, action); } @@ -338,7 +331,7 @@ void SIMIX_host_execution_resume(smx_action_t action) void SIMIX_execution_finish(smx_action_t action) { - xbt_fifo_item_t item; + volatile xbt_fifo_item_t item; smx_req_t req; xbt_fifo_foreach(action->request_list, item, req, smx_req_t) { @@ -346,13 +339,13 @@ void SIMIX_execution_finish(smx_action_t action) switch (action->state) { case SIMIX_DONE: - /* do nothing, action done*/ + /* do nothing, action done */ XBT_DEBUG("SIMIX_execution_finished: execution successful"); break; case SIMIX_FAILED: + XBT_DEBUG("SIMIX_execution_finished: host '%s' failed", req->issuer->smx_host->name); TRY { - XBT_DEBUG("SIMIX_execution_finished: host '%s' failed", req->issuer->smx_host->name); THROWF(host_error, 0, "Host failed"); } CATCH(req->issuer->running_ctx->exception) { @@ -361,8 +354,8 @@ void SIMIX_execution_finish(smx_action_t action) break; case SIMIX_CANCELED: + XBT_DEBUG("SIMIX_execution_finished: execution canceled"); TRY { - XBT_DEBUG("SIMIX_execution_finished: execution canceled"); THROWF(cancel_error, 0, "Canceled"); } CATCH(req->issuer->running_ctx->exception) { @@ -371,7 +364,8 @@ void SIMIX_execution_finish(smx_action_t action) break; default: - THROW_IMPOSSIBLE; + xbt_die("Internal error in SIMIX_execution_finish: unexpected action state %d", + action->state); } req->issuer->waiting_action = NULL; req->host_execution_wait.result = action->state;