- XBT_DEBUG("Cancel synchro %p", synchro);
- simgrid::simix::Exec *exec = static_cast<simgrid::simix::Exec *>(synchro);
-
- if (exec->surf_exec)
- exec->surf_exec->cancel();
-}
-
-void SIMIX_execution_set_priority(smx_synchro_t synchro, double priority)
-{
- simgrid::simix::Exec *exec = static_cast<simgrid::simix::Exec *>(synchro);
- if(exec->surf_exec)
- exec->surf_exec->setPriority(priority);
-}
-
-void SIMIX_execution_set_bound(smx_synchro_t synchro, double bound)
-{
- simgrid::simix::Exec *exec = static_cast<simgrid::simix::Exec *>(synchro);
- if(exec->surf_exec)
- static_cast<simgrid::surf::CpuAction*>(exec->surf_exec)->setBound(bound);
-}
-
-void SIMIX_execution_set_affinity(smx_synchro_t synchro, sg_host_t host, unsigned long mask)
-{
- simgrid::simix::Exec *exec = static_cast<simgrid::simix::Exec *>(synchro);
- if(exec->surf_exec) {
- /* just a double check to confirm that this host is the host where this task is running. */
- xbt_assert(exec->host == host);
- static_cast<simgrid::surf::CpuAction*>(exec->surf_exec)->setAffinity(host->pimpl_cpu, mask);
- }
-}
-
-void simcall_HANDLER_execution_wait(smx_simcall_t simcall, smx_synchro_t synchro)
-{
- simgrid::simix::Exec *exec = static_cast<simgrid::simix::Exec *>(synchro);
- XBT_DEBUG("Wait for execution of synchro %p, state %d", synchro, (int)synchro->state);
+ simgrid::kernel::activity::ExecImplPtr exec =
+ boost::static_pointer_cast<simgrid::kernel::activity::ExecImpl>(synchro);
+ XBT_DEBUG("Wait for execution of synchro %p, state %d", synchro.get(), (int)synchro->state);