XBT_LOG_NEW_DEFAULT_SUBCATEGORY(simix_process, simix,
"Logging specific to SIMIX (process)");
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(simix_process, simix,
"Logging specific to SIMIX (process)");
void SIMIX_process_cleanup(smx_process_t process)
{
DEBUG1("Cleanup process %s", process->name);
void SIMIX_process_cleanup(smx_process_t process)
{
DEBUG1("Cleanup process %s", process->name);
xbt_swag_remove(process, simix_global->process_list);
xbt_swag_remove(process, process->smx_host->process_list);
xbt_swag_insert(process, simix_global->process_to_destroy);
xbt_swag_remove(process, simix_global->process_list);
xbt_swag_remove(process, process->smx_host->process_list);
xbt_swag_insert(process, simix_global->process_to_destroy);
/* Create maestro process and intilialize it */
maestro = xbt_new0(s_smx_process_t, 1);
/* Create maestro process and intilialize it */
maestro = xbt_new0(s_smx_process_t, 1);
maestro->name = (char *) "";
maestro->running_ctx = xbt_new(xbt_running_ctx_t, 1);
XBT_RUNNING_CTX_INITIALIZE(maestro->running_ctx);
maestro->context = SIMIX_context_new(NULL, 0, NULL, NULL, maestro);
maestro->name = (char *) "";
maestro->running_ctx = xbt_new(xbt_running_ctx_t, 1);
XBT_RUNNING_CTX_INITIALIZE(maestro->running_ctx);
maestro->context = SIMIX_context_new(NULL, 0, NULL, NULL, maestro);
/* Now insert it in the global process list and in the process to run list */
xbt_swag_insert(process, simix_global->process_list);
DEBUG2("Inserting %s(%s) in the to_run list", process->name, host->name);
/* Now insert it in the global process list and in the process to run list */
xbt_swag_insert(process, simix_global->process_list);
DEBUG2("Inserting %s(%s) in the to_run list", process->name, host->name);
/* Ok, maestro returned control to us */
DEBUG1("Maestro returned control to me: '%s'", self->name);
/* Ok, maestro returned control to us */
DEBUG1("Maestro returned control to me: '%s'", self->name);