/* Initialize the thread pool data structure */
this->status = PARMAP_WORK;
this->work_round = 0;
- this->workers.reserve(num_workers);
+ this->workers.resize(num_workers);
this->num_workers = num_workers;
this->synchro = new_synchro(mode);
for (unsigned i = 1; i < num_workers; i++)
workers[i]->join();
- workers.clear();
delete synchro;
}
void_pfn_smxprocess_t cleanup_func,
smx_actor_t simix_process)
{
- xbt_assert(simix_global, "simix is not initialized, please call MSG_init first");
return simix_global->context_factory->create_context(
std::move(code), cleanup_func, simix_process);
}