X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/99bdda3ee4939633343432d14d83a58a7f3b77ff..49a75a876cd9b9284722a63f1b3a02d1283630e1:/src/simix/smx_synchro.cpp diff --git a/src/simix/smx_synchro.cpp b/src/simix/smx_synchro.cpp index 0cd3b01a9d..153d7a7d6e 100644 --- a/src/simix/smx_synchro.cpp +++ b/src/simix/smx_synchro.cpp @@ -6,27 +6,13 @@ #include "src/kernel/activity/ConditionVariableImpl.hpp" #include "src/kernel/activity/MutexImpl.hpp" #include "src/kernel/activity/SemaphoreImpl.hpp" -#include "src/kernel/activity/SynchroRaw.hpp" #include "src/kernel/context/Context.hpp" #include "src/simix/smx_synchro_private.hpp" -#include "src/surf/cpu_interface.hpp" XBT_LOG_NEW_DEFAULT_SUBCATEGORY(simix_synchro, simix, "SIMIX Synchronization (mutex, semaphores and conditions)"); /***************************** Raw synchronization *********************************/ -smx_activity_t SIMIX_synchro_wait(sg_host_t smx_host, double timeout) -{ - XBT_IN("(%p, %f)",smx_host,timeout); - - simgrid::kernel::activity::RawImplPtr sync = - simgrid::kernel::activity::RawImplPtr(new simgrid::kernel::activity::RawImpl()); - sync->surf_action_ = smx_host->pimpl_cpu->sleep(timeout); - sync->surf_action_->set_data(sync.get()); - XBT_OUT(); - return sync; -} - void SIMIX_synchro_stop_waiting(smx_actor_t process, smx_simcall_t simcall) { XBT_IN("(%p, %p)",process,simcall); @@ -37,11 +23,11 @@ void SIMIX_synchro_stop_waiting(smx_actor_t process, smx_simcall_t simcall) break; case SIMCALL_COND_WAIT: - simgrid::xbt::intrusive_erase(simcall_cond_wait__get__cond(simcall)->sleeping, *process); + simgrid::xbt::intrusive_erase(simcall_cond_wait__get__cond(simcall)->sleeping_, *process); break; case SIMCALL_COND_WAIT_TIMEOUT: - simgrid::xbt::intrusive_erase(simcall_cond_wait_timeout__get__cond(simcall)->sleeping, *process); + simgrid::xbt::intrusive_erase(simcall_cond_wait_timeout__get__cond(simcall)->sleeping_, *process); simcall_cond_wait_timeout__set__result(simcall, 1); // signal a timeout break;