From: Martin Quinson Date: Sun, 10 May 2020 08:31:26 +0000 (+0200) Subject: stick to our coding standards: fields must have a trailing _ X-Git-Tag: v3.26~611 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/2ccf9c22b2e9dee40858cb70a44763f4084e15da stick to our coding standards: fields must have a trailing _ --- diff --git a/src/kernel/activity/ActivityImpl.cpp b/src/kernel/activity/ActivityImpl.cpp index f62f74f17f..7e163b0e11 100644 --- a/src/kernel/activity/ActivityImpl.cpp +++ b/src/kernel/activity/ActivityImpl.cpp @@ -24,7 +24,7 @@ ActivityImpl::~ActivityImpl() void ActivityImpl::register_simcall(smx_simcall_t simcall) { simcalls_.push_back(simcall); - simcall->issuer_->waiting_synchro = this; + simcall->issuer_->waiting_synchro_ = this; } void ActivityImpl::clean_action() @@ -55,10 +55,10 @@ void ActivityImpl::wait_for(actor::ActorImpl* issuer, double timeout) xbt_assert(std::isfinite(timeout), "timeout is not finite!"); /* Associate this simcall to the synchro */ - register_simcall(&issuer->simcall); + register_simcall(&issuer->simcall_); if (MC_is_active() || MC_record_replay_is_active()) { - int idx = SIMCALL_GET_MC_VALUE(issuer->simcall); + int idx = SIMCALL_GET_MC_VALUE(issuer->simcall_); if (idx == 0) { state_ = simgrid::kernel::activity::State::DONE; } else { diff --git a/src/kernel/activity/CommImpl.cpp b/src/kernel/activity/CommImpl.cpp index d13a1d1e85..d5c1ff3884 100644 --- a/src/kernel/activity/CommImpl.cpp +++ b/src/kernel/activity/CommImpl.cpp @@ -78,7 +78,7 @@ XBT_PRIVATE simgrid::kernel::activity::ActivityImplPtr simcall_HANDLER_comm_isen other_comm->clean_fun = clean_fun; } else { other_comm->clean_fun = nullptr; - src_proc->activities.push_back(other_comm); + src_proc->activities_.push_back(other_comm); } /* Setup the communication synchro */ @@ -162,7 +162,7 @@ simcall_HANDLER_comm_irecv(smx_simcall_t /*simcall*/, smx_actor_t receiver, smx_ other_comm->state_ = simgrid::kernel::activity::State::READY; other_comm->set_type(simgrid::kernel::activity::CommImpl::Type::READY); } - receiver->activities.push_back(other_comm); + receiver->activities_.push_back(other_comm); } /* Setup communication synchro */ @@ -699,18 +699,18 @@ void CommImpl::finish() } } - simcall->issuer_->waiting_synchro = nullptr; - simcall->issuer_->activities.remove(this); + simcall->issuer_->waiting_synchro_ = nullptr; + simcall->issuer_->activities_.remove(this); if (detached_) { if (simcall->issuer_ == src_actor_) { if (dst_actor_) - dst_actor_->activities.remove(this); + dst_actor_->activities_.remove(this); } else if (simcall->issuer_ == dst_actor_) { if (src_actor_) - src_actor_->activities.remove(this); + src_actor_->activities_.remove(this); } else { - dst_actor_->activities.remove(this); - src_actor_->activities.remove(this); + dst_actor_->activities_.remove(this); + src_actor_->activities_.remove(this); } } } diff --git a/src/kernel/activity/ConditionVariableImpl.cpp b/src/kernel/activity/ConditionVariableImpl.cpp index 04d034fb1f..1ec77be538 100644 --- a/src/kernel/activity/ConditionVariableImpl.cpp +++ b/src/kernel/activity/ConditionVariableImpl.cpp @@ -45,10 +45,10 @@ void ConditionVariableImpl::signal() sleeping_.pop_front(); /* Destroy waiter's synchronization */ - proc.waiting_synchro = nullptr; + proc.waiting_synchro_ = nullptr; /* Now transform the cond wait simcall into a mutex lock one */ - smx_simcall_t simcall = &proc.simcall; + smx_simcall_t simcall = &proc.simcall_; MutexImpl* simcall_mutex; if (simcall->call_ == SIMCALL_COND_WAIT) simcall_mutex = simcall_cond_wait__get__mutex(simcall); @@ -91,7 +91,7 @@ void ConditionVariableImpl::wait(smx_mutex_t mutex, double timeout, actor::Actor RawImplPtr synchro(new RawImpl()); synchro->set_host(issuer->get_host()).set_timeout(timeout).start(); - synchro->register_simcall(&issuer->simcall); + synchro->register_simcall(&issuer->simcall_); sleeping_.push_back(*issuer); } diff --git a/src/kernel/activity/ExecImpl.cpp b/src/kernel/activity/ExecImpl.cpp index 29b0ed4459..f4ce2de60a 100644 --- a/src/kernel/activity/ExecImpl.cpp +++ b/src/kernel/activity/ExecImpl.cpp @@ -60,7 +60,7 @@ ExecImpl::ExecImpl() actor::ActorImpl* self = actor::ActorImpl::self(); if (self) { actor_ = self; - self->activities.push_back(this); + self->activities_.push_back(this); } } @@ -166,7 +166,7 @@ void ExecImpl::post() clean_action(); timeout_detector_.reset(); if (actor_) { - actor_->activities.remove(this); + actor_->activities_.remove(this); actor_ = nullptr; } /* Answer all simcalls associated with the synchro */ @@ -239,7 +239,7 @@ void ExecImpl::finish() xbt_die("Internal error in ExecImpl::finish(): unexpected synchro state %d", static_cast(state_)); } - simcall->issuer_->waiting_synchro = nullptr; + simcall->issuer_->waiting_synchro_ = nullptr; /* Fail the process if the host is down */ if (simcall->issuer_->get_host()->is_on()) simcall->issuer_->simcall_answer(); diff --git a/src/kernel/activity/IoImpl.cpp b/src/kernel/activity/IoImpl.cpp index 17df987f99..72e4007085 100644 --- a/src/kernel/activity/IoImpl.cpp +++ b/src/kernel/activity/IoImpl.cpp @@ -117,7 +117,7 @@ void IoImpl::finish() xbt_die("Internal error in IoImpl::finish(): unexpected synchro state %d", static_cast(state_)); } - simcall->issuer_->waiting_synchro = nullptr; + simcall->issuer_->waiting_synchro_ = nullptr; simcall->issuer_->simcall_answer(); } } diff --git a/src/kernel/activity/MutexImpl.cpp b/src/kernel/activity/MutexImpl.cpp index 8505e91484..fd37fd8322 100644 --- a/src/kernel/activity/MutexImpl.cpp +++ b/src/kernel/activity/MutexImpl.cpp @@ -23,8 +23,8 @@ void MutexImpl::lock(actor::ActorImpl* issuer) /* Somebody using the mutex, use a synchronization to get host failures */ synchro = RawImplPtr(new RawImpl()); (*synchro).set_host(issuer->get_host()).start(); - synchro->simcalls_.push_back(&issuer->simcall); - issuer->waiting_synchro = synchro; + synchro->simcalls_.push_back(&issuer->simcall_); + issuer->waiting_synchro_ = synchro; sleeping_.push_back(*issuer); } else { /* mutex free */ @@ -71,7 +71,7 @@ void MutexImpl::unlock(actor::ActorImpl* issuer) /* Give the ownership to the first waiting actor */ owner_ = &sleeping_.front(); sleeping_.pop_front(); - owner_->waiting_synchro = nullptr; + owner_->waiting_synchro_ = nullptr; owner_->simcall_answer(); } else { /* nobody to wake up */ diff --git a/src/kernel/activity/SemaphoreImpl.cpp b/src/kernel/activity/SemaphoreImpl.cpp index ae98e553b3..bf3407eb45 100644 --- a/src/kernel/activity/SemaphoreImpl.cpp +++ b/src/kernel/activity/SemaphoreImpl.cpp @@ -18,7 +18,7 @@ void SemaphoreImpl::acquire(actor::ActorImpl* issuer, double timeout) if (value_ <= 0) { RawImplPtr synchro = RawImplPtr(new RawImpl()); synchro->set_host(issuer->get_host()).set_timeout(timeout).start(); - synchro->register_simcall(&issuer->simcall); + synchro->register_simcall(&issuer->simcall_); sleeping_.push_back(*issuer); } else { value_--; @@ -32,7 +32,7 @@ void SemaphoreImpl::release() if (not sleeping_.empty()) { auto& actor = sleeping_.front(); sleeping_.pop_front(); - actor.waiting_synchro = nullptr; + actor.waiting_synchro_ = nullptr; actor.simcall_answer(); } else { value_++; diff --git a/src/kernel/activity/SleepImpl.cpp b/src/kernel/activity/SleepImpl.cpp index 4df963b9a9..c08a7ab0e1 100644 --- a/src/kernel/activity/SleepImpl.cpp +++ b/src/kernel/activity/SleepImpl.cpp @@ -58,7 +58,7 @@ void SleepImpl::finish() const s_smx_simcall* simcall = simcalls_.front(); simcalls_.pop_front(); - simcall->issuer_->waiting_synchro = nullptr; + simcall->issuer_->waiting_synchro_ = nullptr; if (simcall->issuer_->is_suspended()) { XBT_DEBUG("Wait! This process is suspended and can't wake up now."); simcall->issuer_->suspended_ = false; diff --git a/src/kernel/activity/SynchroRaw.cpp b/src/kernel/activity/SynchroRaw.cpp index 171199b70d..8ff59c5b65 100644 --- a/src/kernel/activity/SynchroRaw.cpp +++ b/src/kernel/activity/SynchroRaw.cpp @@ -103,7 +103,7 @@ void RawImpl::finish() default: THROW_IMPOSSIBLE; } - simcall->issuer_->waiting_synchro = nullptr; + simcall->issuer_->waiting_synchro_ = nullptr; simcall->issuer_->simcall_answer(); } diff --git a/src/kernel/actor/ActorImpl.cpp b/src/kernel/actor/ActorImpl.cpp index 84c85e98fa..258ce94f9a 100644 --- a/src/kernel/actor/ActorImpl.cpp +++ b/src/kernel/actor/ActorImpl.cpp @@ -55,7 +55,7 @@ ActorImpl* ActorImpl::self() ActorImpl::ActorImpl(xbt::string name, s4u::Host* host) : host_(host), name_(std::move(name)), piface_(this) { pid_ = maxpid++; - simcall.issuer_ = this; + simcall_.issuer_ = this; stacksize_ = smx_context_stack_size; } @@ -166,25 +166,25 @@ void ActorImpl::cleanup() undaemonize(); /* cancel non-blocking activities */ - for (auto activity : activities) + for (auto activity : activities_) activity->cancel(); - activities.clear(); + activities_.clear(); XBT_DEBUG("%s@%s(%ld) should not run anymore", get_cname(), get_host()->get_cname(), get_pid()); if (this == simix_global->maestro_) /* Do not cleanup maestro */ return; - XBT_DEBUG("Cleanup actor %s (%p), waiting synchro %p", get_cname(), this, waiting_synchro.get()); + XBT_DEBUG("Cleanup actor %s (%p), waiting synchro %p", get_cname(), this, waiting_synchro_.get()); /* Unregister associated timers if any */ - if (kill_timer != nullptr) { - kill_timer->remove(); - kill_timer = nullptr; + if (kill_timer_ != nullptr) { + kill_timer_->remove(); + kill_timer_ = nullptr; } - if (simcall.timeout_cb_) { - simcall.timeout_cb_->remove(); - simcall.timeout_cb_ = nullptr; + if (simcall_.timeout_cb_) { + simcall_.timeout_cb_->remove(); + simcall_.timeout_cb_ = nullptr; } cleanup_from_simix(); @@ -201,26 +201,26 @@ void ActorImpl::exit() exception_ = nullptr; /* destroy the blocking synchro if any */ - if (waiting_synchro != nullptr) { - waiting_synchro->cancel(); - waiting_synchro->state_ = activity::State::FAILED; + if (waiting_synchro_ != nullptr) { + waiting_synchro_->cancel(); + waiting_synchro_->state_ = activity::State::FAILED; - activity::ExecImplPtr exec = boost::dynamic_pointer_cast(waiting_synchro); - activity::CommImplPtr comm = boost::dynamic_pointer_cast(waiting_synchro); + activity::ExecImplPtr exec = boost::dynamic_pointer_cast(waiting_synchro_); + activity::CommImplPtr comm = boost::dynamic_pointer_cast(waiting_synchro_); if (exec != nullptr) { exec->clean_action(); } else if (comm != nullptr) { // Remove first occurrence of &actor->simcall: - auto i = boost::range::find(waiting_synchro->simcalls_, &simcall); - if (i != waiting_synchro->simcalls_.end()) - waiting_synchro->simcalls_.remove(&simcall); + auto i = boost::range::find(waiting_synchro_->simcalls_, &simcall_); + if (i != waiting_synchro_->simcalls_.end()) + waiting_synchro_->simcalls_.remove(&simcall_); } else { - activity::ActivityImplPtr(waiting_synchro)->finish(); + activity::ActivityImplPtr(waiting_synchro_)->finish(); } - activities.remove(waiting_synchro); - waiting_synchro = nullptr; + activities_.remove(waiting_synchro_); + waiting_synchro_ = nullptr; } // Forcefully kill the actor if its host is turned off. Not a HostFailureException because you should not survive that @@ -264,15 +264,15 @@ void ActorImpl::set_kill_time(double kill_time) if (kill_time <= SIMIX_get_clock()) return; XBT_DEBUG("Set kill time %f for actor %s@%s", kill_time, get_cname(), host_->get_cname()); - kill_timer = simix::Timer::set(kill_time, [this] { + kill_timer_ = simix::Timer::set(kill_time, [this] { this->exit(); - kill_timer = nullptr; + kill_timer_ = nullptr; }); } double ActorImpl::get_kill_time() { - return kill_timer ? kill_timer->get_date() : 0; + return kill_timer_ ? kill_timer_->get_date() : 0; } void ActorImpl::yield() @@ -367,14 +367,14 @@ void ActorImpl::suspend() suspended_ = true; /* If the suspended actor is waiting on a sync, suspend its synchronization. */ - if (waiting_synchro == nullptr) { + if (waiting_synchro_ == nullptr) { auto exec = new activity::ExecImpl(); exec->set_name("suspend").set_host(host_).set_flops_amount(0.0).start(); - waiting_synchro = activity::ExecImplPtr(exec); + waiting_synchro_ = activity::ExecImplPtr(exec); - waiting_synchro->simcalls_.push_back(&simcall); + waiting_synchro_->simcalls_.push_back(&simcall_); } - waiting_synchro->suspend(); + waiting_synchro_->suspend(); } void ActorImpl::resume() @@ -391,8 +391,8 @@ void ActorImpl::resume() suspended_ = false; /* resume the synchronization that was blocking the resumed actor. */ - if (waiting_synchro) - waiting_synchro->resume(); + if (waiting_synchro_) + waiting_synchro_->resume(); XBT_OUT(); } @@ -426,20 +426,20 @@ void ActorImpl::throw_exception(std::exception_ptr e) resume(); /* cancel the blocking synchro if any */ - if (waiting_synchro) { - waiting_synchro->cancel(); - activities.remove(waiting_synchro); - waiting_synchro = nullptr; + if (waiting_synchro_) { + waiting_synchro_->cancel(); + activities_.remove(waiting_synchro_); + waiting_synchro_ = nullptr; } } void ActorImpl::simcall_answer() { if (this != simix_global->maestro_) { - XBT_DEBUG("Answer simcall %s (%d) issued by %s (%p)", SIMIX_simcall_name(simcall.call_), (int)simcall.call_, + XBT_DEBUG("Answer simcall %s (%d) issued by %s (%p)", SIMIX_simcall_name(simcall_.call_), (int)simcall_.call_, get_cname(), this); - xbt_assert(simcall.call_ != SIMCALL_NONE); - simcall.call_ = SIMCALL_NONE; + xbt_assert(simcall_.call_ != SIMCALL_NONE); + simcall_.call_ = SIMCALL_NONE; xbt_assert(not XBT_LOG_ISENABLED(simix_process, xbt_log_priority_debug) || std::find(begin(simix_global->actors_to_run), end(simix_global->actors_to_run), this) == end(simix_global->actors_to_run), @@ -528,7 +528,7 @@ void create_maestro(const std::function& code) maestro->context_.reset(simix_global->context_factory->create_maestro(ActorCode(code), maestro)); } - maestro->simcall.issuer_ = maestro; + maestro->simcall_.issuer_ = maestro; simix_global->maestro_ = maestro; } diff --git a/src/kernel/actor/ActorImpl.hpp b/src/kernel/actor/ActorImpl.hpp index 9349f8f21d..276eb214e4 100644 --- a/src/kernel/actor/ActorImpl.hpp +++ b/src/kernel/actor/ActorImpl.hpp @@ -68,15 +68,15 @@ public: bool finished_ = false; bool suspended_ = false; - activity::ActivityImplPtr waiting_synchro = nullptr; /* the current blocking synchro if any */ - std::list activities; /* the current non-blocking synchros */ - s_smx_simcall simcall; + activity::ActivityImplPtr waiting_synchro_ = nullptr; /* the current blocking synchro if any */ + std::list activities_; /* the current non-blocking synchros */ + s_smx_simcall simcall_; /* list of functions executed when the process dies */ std::shared_ptr>> on_exit = std::make_shared>>(); std::function code_; - simix::Timer* kill_timer = nullptr; + simix::Timer* kill_timer_ = nullptr; private: /* Refcounting */ diff --git a/src/mc/checker/CommunicationDeterminismChecker.cpp b/src/mc/checker/CommunicationDeterminismChecker.cpp index d7c436effc..7d112063e6 100644 --- a/src/mc/checker/CommunicationDeterminismChecker.cpp +++ b/src/mc/checker/CommunicationDeterminismChecker.cpp @@ -392,7 +392,7 @@ void CommunicationDeterminismChecker::restoreState() real one, pointed by the request field of the issuer process */ const smx_actor_t issuer = MC_smx_simcall_get_issuer(saved_req); - smx_simcall_t req = &issuer->simcall; + smx_simcall_t req = &issuer->simcall_; /* TODO : handle test and testany simcalls */ e_mc_call_type_t call = MC_get_call_type(req); diff --git a/src/mc/checker/LivenessChecker.cpp b/src/mc/checker/LivenessChecker.cpp index e3e7735ebe..b04c743a4b 100644 --- a/src/mc/checker/LivenessChecker.cpp +++ b/src/mc/checker/LivenessChecker.cpp @@ -149,7 +149,7 @@ void LivenessChecker::replay() /* because we got a copy of the executed request, we have to fetch the real one, pointed by the request field of the issuer process */ const smx_actor_t issuer = MC_smx_simcall_get_issuer(saved_req); - req = &issuer->simcall; + req = &issuer->simcall_; /* Debug information */ XBT_DEBUG("Replay (depth = %d) : %s (%p)", depth, diff --git a/src/mc/mc_base.cpp b/src/mc/mc_base.cpp index b8300dbb10..fcb4fa08e5 100644 --- a/src/mc/mc_base.cpp +++ b/src/mc/mc_base.cpp @@ -43,7 +43,7 @@ void wait_for_requests() while (not simix_global->actors_to_run.empty()) { simix_global->run_all_actors(); for (smx_actor_t const& process : simix_global->actors_that_ran) { - const s_smx_simcall* req = &process->simcall; + const s_smx_simcall* req = &process->simcall_; if (req->call_ != SIMCALL_NONE && not simgrid::mc::request_is_visible(req)) process->simcall_handle(0); } @@ -78,7 +78,7 @@ bool actor_is_enabled(smx_actor_t actor) #endif // Now, we are in the client app, no need for remote memory reading. - smx_simcall_t req = &actor->simcall; + smx_simcall_t req = &actor->simcall_; if (req->inspector_ != nullptr) return req->inspector_->is_enabled(); diff --git a/src/mc/mc_record.cpp b/src/mc/mc_record.cpp index 78e34fee4a..bfd548239d 100644 --- a/src/mc/mc_record.cpp +++ b/src/mc/mc_record.cpp @@ -34,7 +34,7 @@ void replay(RecordTrace const& trace) smx_actor_t process = SIMIX_process_from_PID(transition.pid_); if (not process) xbt_die("Unexpected process (pid:%d).", transition.pid_); - const s_smx_simcall* simcall = &(process->simcall); + const s_smx_simcall* simcall = &(process->simcall_); if (simcall == nullptr || simcall->call_ == SIMCALL_NONE) xbt_die("No simcall for process %d.", transition.pid_); if (not simgrid::mc::request_is_visible(simcall) || not simgrid::mc::actor_is_enabled(process)) diff --git a/src/mc/mc_state.cpp b/src/mc/mc_state.cpp index 7a3c5c74c3..ec1e42ac48 100644 --- a/src/mc/mc_state.cpp +++ b/src/mc/mc_state.cpp @@ -68,11 +68,11 @@ static inline smx_simcall_t MC_state_choose_request_for_process(simgrid::mc::Sta return nullptr; // Not executable in the application smx_simcall_t req = nullptr; - switch (actor->simcall.call_) { + switch (actor->simcall_.call_) { case SIMCALL_COMM_WAITANY: state->transition_.argument_ = -1; - while (procstate->times_considered < simcall_comm_waitany__get__count(&actor->simcall)) { - if (simgrid::mc::request_is_enabled_by_idx(&actor->simcall, procstate->times_considered)) { + while (procstate->times_considered < simcall_comm_waitany__get__count(&actor->simcall_)) { + if (simgrid::mc::request_is_enabled_by_idx(&actor->simcall_, procstate->times_considered)) { state->transition_.argument_ = procstate->times_considered; ++procstate->times_considered; break; @@ -80,17 +80,17 @@ static inline smx_simcall_t MC_state_choose_request_for_process(simgrid::mc::Sta ++procstate->times_considered; } - if (procstate->times_considered >= simcall_comm_waitany__get__count(&actor->simcall)) + if (procstate->times_considered >= simcall_comm_waitany__get__count(&actor->simcall_)) procstate->set_done(); if (state->transition_.argument_ != -1) - req = &actor->simcall; + req = &actor->simcall_; break; case SIMCALL_COMM_TESTANY: { unsigned start_count = procstate->times_considered; state->transition_.argument_ = -1; - while (procstate->times_considered < simcall_comm_testany__get__count(&actor->simcall)) { - if (simgrid::mc::request_is_enabled_by_idx(&actor->simcall, procstate->times_considered)) { + while (procstate->times_considered < simcall_comm_testany__get__count(&actor->simcall_)) { + if (simgrid::mc::request_is_enabled_by_idx(&actor->simcall_, procstate->times_considered)) { state->transition_.argument_ = procstate->times_considered; ++procstate->times_considered; break; @@ -98,18 +98,18 @@ static inline smx_simcall_t MC_state_choose_request_for_process(simgrid::mc::Sta ++procstate->times_considered; } - if (procstate->times_considered >= simcall_comm_testany__get__count(&actor->simcall)) + if (procstate->times_considered >= simcall_comm_testany__get__count(&actor->simcall_)) procstate->set_done(); if (state->transition_.argument_ != -1 || start_count == 0) - req = &actor->simcall; + req = &actor->simcall_; break; } case SIMCALL_COMM_WAIT: { simgrid::mc::RemotePtr remote_act = - remote(static_cast(simcall_comm_wait__getraw__comm(&actor->simcall))); + remote(static_cast(simcall_comm_wait__getraw__comm(&actor->simcall_))); simgrid::mc::Remote temp_act; mc_model_checker->get_remote_simulation().read(temp_act, remote_act); const simgrid::kernel::activity::CommImpl* act = temp_act.get_buffer(); @@ -121,24 +121,24 @@ static inline smx_simcall_t MC_state_choose_request_for_process(simgrid::mc::Sta else state->transition_.argument_ = -1; // timeout procstate->set_done(); - req = &actor->simcall; + req = &actor->simcall_; break; } case SIMCALL_MC_RANDOM: { - int min_value = simcall_mc_random__get__min(&actor->simcall); + int min_value = simcall_mc_random__get__min(&actor->simcall_); state->transition_.argument_ = procstate->times_considered + min_value; procstate->times_considered++; - if (state->transition_.argument_ == simcall_mc_random__get__max(&actor->simcall)) + if (state->transition_.argument_ == simcall_mc_random__get__max(&actor->simcall_)) procstate->set_done(); - req = &actor->simcall; + req = &actor->simcall_; break; } default: procstate->set_done(); state->transition_.argument_ = 0; - req = &actor->simcall; + req = &actor->simcall_; break; } if (not req) diff --git a/src/s4u/s4u_Actor.cpp b/src/s4u/s4u_Actor.cpp index 8a6dbb87f1..e6737e9342 100644 --- a/src/s4u/s4u_Actor.cpp +++ b/src/s4u/s4u_Actor.cpp @@ -118,7 +118,7 @@ void Actor::join(double timeout) issuer->simcall_answer(); } else { kernel::activity::ActivityImplPtr sync = issuer->join(target, timeout); - sync->register_simcall(&issuer->simcall); + sync->register_simcall(&issuer->simcall_); } }); } @@ -155,11 +155,11 @@ void Actor::set_host(Host* new_host) const s4u::Host* previous_location = get_host(); kernel::actor::simcall([this, new_host]() { - if (pimpl_->waiting_synchro != nullptr) { + if (pimpl_->waiting_synchro_ != nullptr) { // The actor is blocked on an activity. If it's an exec, migrate it too. // FIXME: implement the migration of other kinds of activities kernel::activity::ExecImplPtr exec = - boost::dynamic_pointer_cast(pimpl_->waiting_synchro); + boost::dynamic_pointer_cast(pimpl_->waiting_synchro_); xbt_assert(exec.get() != nullptr, "We can only migrate blocked actors when they are blocked on executions."); exec->migrate(new_host); } @@ -327,7 +327,7 @@ void sleep_for(double duration) return; } kernel::activity::ActivityImplPtr sync = issuer->sleep(duration); - sync->register_simcall(&issuer->simcall); + sync->register_simcall(&issuer->simcall_); }); Actor::on_wake_up(*issuer->ciface()); diff --git a/src/simix/libsmx.cpp b/src/simix/libsmx.cpp index 8d915db35b..5830d3254e 100644 --- a/src/simix/libsmx.cpp +++ b/src/simix/libsmx.cpp @@ -351,13 +351,13 @@ bool simcall_io_test(const simgrid::kernel::activity::ActivityImplPtr& io) // XB void simcall_run_kernel(std::function const& code, simgrid::mc::SimcallInspector* t) { - simgrid::kernel::actor::ActorImpl::self()->simcall.inspector_ = t; + simgrid::kernel::actor::ActorImpl::self()->simcall_.inspector_ = t; simcall_BODY_run_kernel(&code); } void simcall_run_blocking(std::function const& code, simgrid::mc::SimcallInspector* t = nullptr) { - simgrid::kernel::actor::ActorImpl::self()->simcall.inspector_ = t; + simgrid::kernel::actor::ActorImpl::self()->simcall_.inspector_ = t; simcall_BODY_run_blocking(&code); } diff --git a/src/simix/popping_bodies.cpp b/src/simix/popping_bodies.cpp index 4962cfa603..d284a1603c 100644 --- a/src/simix/popping_bodies.cpp +++ b/src/simix/popping_bodies.cpp @@ -28,133 +28,133 @@ template inline static R simcall(e_smx_simcall_t call, T const&... t) { smx_actor_t self = SIMIX_process_self(); - simgrid::simix::marshal(&self->simcall, call, t...); + simgrid::simix::marshal(&self->simcall_, call, t...); if (self != simix_global->maestro_) { - XBT_DEBUG("Yield process '%s' on simcall %s (%d)", self->get_cname(), SIMIX_simcall_name(self->simcall.call_), - (int)self->simcall.call_); + XBT_DEBUG("Yield process '%s' on simcall %s (%d)", self->get_cname(), SIMIX_simcall_name(self->simcall_.call_), + (int)self->simcall_.call_); self->yield(); } else { self->simcall_handle(0); } - return simgrid::simix::unmarshal(self->simcall.result_); + return simgrid::simix::unmarshal(self->simcall_.result_); } inline static int simcall_BODY_execution_waitany_for(simgrid::kernel::activity::ExecImpl** execs, size_t count, double timeout) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_execution_waitany_for(&SIMIX_process_self()->simcall, execs, count, timeout); + simcall_HANDLER_execution_waitany_for(&SIMIX_process_self()->simcall_, execs, count, timeout); return simcall(SIMCALL_EXECUTION_WAITANY_FOR, execs, count, timeout); } inline static void simcall_BODY_comm_send(smx_actor_t sender, smx_mailbox_t mbox, double task_size, double rate, unsigned char* src_buff, size_t src_buff_size, simix_match_func_t match_fun, simix_copy_data_func_t copy_data_fun, void* data, double timeout) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_send(&SIMIX_process_self()->simcall, sender, mbox, task_size, rate, src_buff, src_buff_size, match_fun, copy_data_fun, data, timeout); + simcall_HANDLER_comm_send(&SIMIX_process_self()->simcall_, sender, mbox, task_size, rate, src_buff, src_buff_size, match_fun, copy_data_fun, data, timeout); return simcall(SIMCALL_COMM_SEND, sender, mbox, task_size, rate, src_buff, src_buff_size, match_fun, copy_data_fun, data, timeout); } inline static boost::intrusive_ptr simcall_BODY_comm_isend(smx_actor_t sender, smx_mailbox_t mbox, double task_size, double rate, unsigned char* src_buff, size_t src_buff_size, simix_match_func_t match_fun, simix_clean_func_t clean_fun, simix_copy_data_func_t copy_data_fun, void* data, bool detached) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_isend(&SIMIX_process_self()->simcall, sender, mbox, task_size, rate, src_buff, src_buff_size, match_fun, clean_fun, copy_data_fun, data, detached); + simcall_HANDLER_comm_isend(&SIMIX_process_self()->simcall_, sender, mbox, task_size, rate, src_buff, src_buff_size, match_fun, clean_fun, copy_data_fun, data, detached); return simcall, smx_actor_t, smx_mailbox_t, double, double, unsigned char*, size_t, simix_match_func_t, simix_clean_func_t, simix_copy_data_func_t, void*, bool>(SIMCALL_COMM_ISEND, sender, mbox, task_size, rate, src_buff, src_buff_size, match_fun, clean_fun, copy_data_fun, data, detached); } inline static void simcall_BODY_comm_recv(smx_actor_t receiver, smx_mailbox_t mbox, unsigned char* dst_buff, size_t* dst_buff_size, simix_match_func_t match_fun, simix_copy_data_func_t copy_data_fun, void* data, double timeout, double rate) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_recv(&SIMIX_process_self()->simcall, receiver, mbox, dst_buff, dst_buff_size, match_fun, copy_data_fun, data, timeout, rate); + simcall_HANDLER_comm_recv(&SIMIX_process_self()->simcall_, receiver, mbox, dst_buff, dst_buff_size, match_fun, copy_data_fun, data, timeout, rate); return simcall(SIMCALL_COMM_RECV, receiver, mbox, dst_buff, dst_buff_size, match_fun, copy_data_fun, data, timeout, rate); } inline static boost::intrusive_ptr simcall_BODY_comm_irecv(smx_actor_t receiver, smx_mailbox_t mbox, unsigned char* dst_buff, size_t* dst_buff_size, simix_match_func_t match_fun, simix_copy_data_func_t copy_data_fun, void* data, double rate) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_irecv(&SIMIX_process_self()->simcall, receiver, mbox, dst_buff, dst_buff_size, match_fun, copy_data_fun, data, rate); + simcall_HANDLER_comm_irecv(&SIMIX_process_self()->simcall_, receiver, mbox, dst_buff, dst_buff_size, match_fun, copy_data_fun, data, rate); return simcall, smx_actor_t, smx_mailbox_t, unsigned char*, size_t*, simix_match_func_t, simix_copy_data_func_t, void*, double>(SIMCALL_COMM_IRECV, receiver, mbox, dst_buff, dst_buff_size, match_fun, copy_data_fun, data, rate); } inline static int simcall_BODY_comm_waitany(simgrid::kernel::activity::CommImpl** comms, size_t count, double timeout) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_waitany(&SIMIX_process_self()->simcall, comms, count, timeout); + simcall_HANDLER_comm_waitany(&SIMIX_process_self()->simcall_, comms, count, timeout); return simcall(SIMCALL_COMM_WAITANY, comms, count, timeout); } inline static void simcall_BODY_comm_wait(simgrid::kernel::activity::CommImpl* comm, double timeout) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_wait(&SIMIX_process_self()->simcall, comm, timeout); + simcall_HANDLER_comm_wait(&SIMIX_process_self()->simcall_, comm, timeout); return simcall(SIMCALL_COMM_WAIT, comm, timeout); } inline static bool simcall_BODY_comm_test(simgrid::kernel::activity::CommImpl* comm) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_test(&SIMIX_process_self()->simcall, comm); + simcall_HANDLER_comm_test(&SIMIX_process_self()->simcall_, comm); return simcall(SIMCALL_COMM_TEST, comm); } inline static int simcall_BODY_comm_testany(simgrid::kernel::activity::CommImpl** comms, size_t count) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_comm_testany(&SIMIX_process_self()->simcall, comms, count); + simcall_HANDLER_comm_testany(&SIMIX_process_self()->simcall_, comms, count); return simcall(SIMCALL_COMM_TESTANY, comms, count); } inline static void simcall_BODY_mutex_lock(smx_mutex_t mutex) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_mutex_lock(&SIMIX_process_self()->simcall, mutex); + simcall_HANDLER_mutex_lock(&SIMIX_process_self()->simcall_, mutex); return simcall(SIMCALL_MUTEX_LOCK, mutex); } inline static int simcall_BODY_mutex_trylock(smx_mutex_t mutex) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_mutex_trylock(&SIMIX_process_self()->simcall, mutex); + simcall_HANDLER_mutex_trylock(&SIMIX_process_self()->simcall_, mutex); return simcall(SIMCALL_MUTEX_TRYLOCK, mutex); } inline static void simcall_BODY_mutex_unlock(smx_mutex_t mutex) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_mutex_unlock(&SIMIX_process_self()->simcall, mutex); + simcall_HANDLER_mutex_unlock(&SIMIX_process_self()->simcall_, mutex); return simcall(SIMCALL_MUTEX_UNLOCK, mutex); } inline static void simcall_BODY_cond_wait(smx_cond_t cond, smx_mutex_t mutex) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_cond_wait(&SIMIX_process_self()->simcall, cond, mutex); + simcall_HANDLER_cond_wait(&SIMIX_process_self()->simcall_, cond, mutex); return simcall(SIMCALL_COND_WAIT, cond, mutex); } inline static int simcall_BODY_cond_wait_timeout(smx_cond_t cond, smx_mutex_t mutex, double timeout) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_cond_wait_timeout(&SIMIX_process_self()->simcall, cond, mutex, timeout); + simcall_HANDLER_cond_wait_timeout(&SIMIX_process_self()->simcall_, cond, mutex, timeout); return simcall(SIMCALL_COND_WAIT_TIMEOUT, cond, mutex, timeout); } inline static void simcall_BODY_sem_acquire(smx_sem_t sem) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_sem_acquire(&SIMIX_process_self()->simcall, sem); + simcall_HANDLER_sem_acquire(&SIMIX_process_self()->simcall_, sem); return simcall(SIMCALL_SEM_ACQUIRE, sem); } inline static int simcall_BODY_sem_acquire_timeout(smx_sem_t sem, double timeout) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_sem_acquire_timeout(&SIMIX_process_self()->simcall, sem, timeout); + simcall_HANDLER_sem_acquire_timeout(&SIMIX_process_self()->simcall_, sem, timeout); return simcall(SIMCALL_SEM_ACQUIRE_TIMEOUT, sem, timeout); } inline static int simcall_BODY_mc_random(int min, int max) { if (0) /* Go to that function to follow the code flow through the simcall barrier */ - simcall_HANDLER_mc_random(&SIMIX_process_self()->simcall, min, max); + simcall_HANDLER_mc_random(&SIMIX_process_self()->simcall_, min, max); return simcall(SIMCALL_MC_RANDOM, min, max); } diff --git a/src/simix/popping_generated.cpp b/src/simix/popping_generated.cpp index 51d3b67a39..5cc7d5132d 100644 --- a/src/simix/popping_generated.cpp +++ b/src/simix/popping_generated.cpp @@ -53,91 +53,91 @@ const char* simcall_names[] = { * This function is generated from src/simix/simcalls.in */ void simgrid::kernel::actor::ActorImpl::simcall_handle(int value) { - XBT_DEBUG("Handling simcall %p: %s", &simcall, SIMIX_simcall_name(simcall.call_)); - SIMCALL_SET_MC_VALUE(simcall, value); + XBT_DEBUG("Handling simcall %p: %s", &simcall_, SIMIX_simcall_name(simcall_.call_)); + SIMCALL_SET_MC_VALUE(simcall_, value); if (context_->wannadie()) return; - switch (simcall.call_) { + switch (simcall_.call_) { case SIMCALL_EXECUTION_WAITANY_FOR: - simcall_HANDLER_execution_waitany_for(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2])); + simcall_HANDLER_execution_waitany_for(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2])); break; case SIMCALL_COMM_SEND: - simcall_HANDLER_comm_send(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2]), simgrid::simix::unmarshal(simcall.args_[3]), simgrid::simix::unmarshal(simcall.args_[4]), simgrid::simix::unmarshal(simcall.args_[5]), simgrid::simix::unmarshal(simcall.args_[6]), simgrid::simix::unmarshal(simcall.args_[7]), simgrid::simix::unmarshal(simcall.args_[8]), simgrid::simix::unmarshal(simcall.args_[9])); + simcall_HANDLER_comm_send(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2]), simgrid::simix::unmarshal(simcall_.args_[3]), simgrid::simix::unmarshal(simcall_.args_[4]), simgrid::simix::unmarshal(simcall_.args_[5]), simgrid::simix::unmarshal(simcall_.args_[6]), simgrid::simix::unmarshal(simcall_.args_[7]), simgrid::simix::unmarshal(simcall_.args_[8]), simgrid::simix::unmarshal(simcall_.args_[9])); break; case SIMCALL_COMM_ISEND: - simgrid::simix::marshal>(simcall.result_, simcall_HANDLER_comm_isend(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2]), simgrid::simix::unmarshal(simcall.args_[3]), simgrid::simix::unmarshal(simcall.args_[4]), simgrid::simix::unmarshal(simcall.args_[5]), simgrid::simix::unmarshal(simcall.args_[6]), simgrid::simix::unmarshal(simcall.args_[7]), simgrid::simix::unmarshal(simcall.args_[8]), simgrid::simix::unmarshal(simcall.args_[9]), simgrid::simix::unmarshal(simcall.args_[10]))); + simgrid::simix::marshal>(simcall_.result_, simcall_HANDLER_comm_isend(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2]), simgrid::simix::unmarshal(simcall_.args_[3]), simgrid::simix::unmarshal(simcall_.args_[4]), simgrid::simix::unmarshal(simcall_.args_[5]), simgrid::simix::unmarshal(simcall_.args_[6]), simgrid::simix::unmarshal(simcall_.args_[7]), simgrid::simix::unmarshal(simcall_.args_[8]), simgrid::simix::unmarshal(simcall_.args_[9]), simgrid::simix::unmarshal(simcall_.args_[10]))); simcall_answer(); break; case SIMCALL_COMM_RECV: - simcall_HANDLER_comm_recv(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2]), simgrid::simix::unmarshal(simcall.args_[3]), simgrid::simix::unmarshal(simcall.args_[4]), simgrid::simix::unmarshal(simcall.args_[5]), simgrid::simix::unmarshal(simcall.args_[6]), simgrid::simix::unmarshal(simcall.args_[7]), simgrid::simix::unmarshal(simcall.args_[8])); + simcall_HANDLER_comm_recv(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2]), simgrid::simix::unmarshal(simcall_.args_[3]), simgrid::simix::unmarshal(simcall_.args_[4]), simgrid::simix::unmarshal(simcall_.args_[5]), simgrid::simix::unmarshal(simcall_.args_[6]), simgrid::simix::unmarshal(simcall_.args_[7]), simgrid::simix::unmarshal(simcall_.args_[8])); break; case SIMCALL_COMM_IRECV: - simgrid::simix::marshal>(simcall.result_, simcall_HANDLER_comm_irecv(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2]), simgrid::simix::unmarshal(simcall.args_[3]), simgrid::simix::unmarshal(simcall.args_[4]), simgrid::simix::unmarshal(simcall.args_[5]), simgrid::simix::unmarshal(simcall.args_[6]), simgrid::simix::unmarshal(simcall.args_[7]))); + simgrid::simix::marshal>(simcall_.result_, simcall_HANDLER_comm_irecv(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2]), simgrid::simix::unmarshal(simcall_.args_[3]), simgrid::simix::unmarshal(simcall_.args_[4]), simgrid::simix::unmarshal(simcall_.args_[5]), simgrid::simix::unmarshal(simcall_.args_[6]), simgrid::simix::unmarshal(simcall_.args_[7]))); simcall_answer(); break; case SIMCALL_COMM_WAITANY: - simcall_HANDLER_comm_waitany(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2])); + simcall_HANDLER_comm_waitany(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2])); break; case SIMCALL_COMM_WAIT: - simcall_HANDLER_comm_wait(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1])); + simcall_HANDLER_comm_wait(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1])); break; case SIMCALL_COMM_TEST: - simcall_HANDLER_comm_test(&simcall, simgrid::simix::unmarshal(simcall.args_[0])); + simcall_HANDLER_comm_test(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0])); break; case SIMCALL_COMM_TESTANY: - simcall_HANDLER_comm_testany(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1])); + simcall_HANDLER_comm_testany(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1])); break; case SIMCALL_MUTEX_LOCK: - simcall_HANDLER_mutex_lock(&simcall, simgrid::simix::unmarshal(simcall.args_[0])); + simcall_HANDLER_mutex_lock(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0])); break; case SIMCALL_MUTEX_TRYLOCK: - simgrid::simix::marshal(simcall.result_, simcall_HANDLER_mutex_trylock(&simcall, simgrid::simix::unmarshal(simcall.args_[0]))); + simgrid::simix::marshal(simcall_.result_, simcall_HANDLER_mutex_trylock(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]))); simcall_answer(); break; case SIMCALL_MUTEX_UNLOCK: - simcall_HANDLER_mutex_unlock(&simcall, simgrid::simix::unmarshal(simcall.args_[0])); + simcall_HANDLER_mutex_unlock(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0])); simcall_answer(); break; case SIMCALL_COND_WAIT: - simcall_HANDLER_cond_wait(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1])); + simcall_HANDLER_cond_wait(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1])); break; case SIMCALL_COND_WAIT_TIMEOUT: - simcall_HANDLER_cond_wait_timeout(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]), simgrid::simix::unmarshal(simcall.args_[2])); + simcall_HANDLER_cond_wait_timeout(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]), simgrid::simix::unmarshal(simcall_.args_[2])); break; case SIMCALL_SEM_ACQUIRE: - simcall_HANDLER_sem_acquire(&simcall, simgrid::simix::unmarshal(simcall.args_[0])); + simcall_HANDLER_sem_acquire(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0])); break; case SIMCALL_SEM_ACQUIRE_TIMEOUT: - simcall_HANDLER_sem_acquire_timeout(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1])); + simcall_HANDLER_sem_acquire_timeout(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1])); break; case SIMCALL_MC_RANDOM: - simgrid::simix::marshal(simcall.result_, simcall_HANDLER_mc_random(&simcall, simgrid::simix::unmarshal(simcall.args_[0]), simgrid::simix::unmarshal(simcall.args_[1]))); + simgrid::simix::marshal(simcall_.result_, simcall_HANDLER_mc_random(&simcall_, simgrid::simix::unmarshal(simcall_.args_[0]), simgrid::simix::unmarshal(simcall_.args_[1]))); simcall_answer(); break; case SIMCALL_RUN_KERNEL: - SIMIX_run_kernel(simgrid::simix::unmarshal const*>(simcall.args_[0])); + SIMIX_run_kernel(simgrid::simix::unmarshal const*>(simcall_.args_[0])); simcall_answer(); break; case SIMCALL_RUN_BLOCKING: - SIMIX_run_blocking(simgrid::simix::unmarshal const*>(simcall.args_[0])); + SIMIX_run_blocking(simgrid::simix::unmarshal const*>(simcall_.args_[0])); break; case NUM_SIMCALLS: diff --git a/src/simix/smx_global.cpp b/src/simix/smx_global.cpp index 7b83e7639f..1c386734d5 100644 --- a/src/simix/smx_global.cpp +++ b/src/simix/smx_global.cpp @@ -228,32 +228,32 @@ void Global::display_all_actor_status() for (auto const& kv : process_list) { kernel::actor::ActorImpl* actor = kv.second; - if (actor->waiting_synchro) { + if (actor->waiting_synchro_) { const char* synchro_description = "unknown"; // we don't care about the Activity type to get its name, use RawImpl const char* name = boost::static_pointer_cast>( - actor->waiting_synchro) + actor->waiting_synchro_) ->get_cname(); - if (boost::dynamic_pointer_cast(actor->waiting_synchro) != nullptr) + if (boost::dynamic_pointer_cast(actor->waiting_synchro_) != nullptr) synchro_description = "execution"; - if (boost::dynamic_pointer_cast(actor->waiting_synchro) != nullptr) + if (boost::dynamic_pointer_cast(actor->waiting_synchro_) != nullptr) synchro_description = "communication"; - if (boost::dynamic_pointer_cast(actor->waiting_synchro) != nullptr) + if (boost::dynamic_pointer_cast(actor->waiting_synchro_) != nullptr) synchro_description = "sleeping"; - if (boost::dynamic_pointer_cast(actor->waiting_synchro) != nullptr) + if (boost::dynamic_pointer_cast(actor->waiting_synchro_) != nullptr) synchro_description = "synchronization"; - if (boost::dynamic_pointer_cast(actor->waiting_synchro) != nullptr) + if (boost::dynamic_pointer_cast(actor->waiting_synchro_) != nullptr) synchro_description = "I/O"; XBT_INFO("Actor %ld (%s@%s): waiting for %s activity %#zx (%s) in state %d to finish", actor->get_pid(), actor->get_cname(), actor->get_host()->get_cname(), synchro_description, - (xbt_log_no_loc ? (size_t)0xDEADBEEF : (size_t)actor->waiting_synchro.get()), name, - (int)actor->waiting_synchro->state_); + (xbt_log_no_loc ? (size_t)0xDEADBEEF : (size_t)actor->waiting_synchro_.get()), name, + (int)actor->waiting_synchro_->state_); } else { XBT_INFO("Actor %ld (%s@%s)", actor->get_pid(), actor->get_cname(), actor->get_host()->get_cname()); } @@ -506,7 +506,7 @@ void SIMIX_run() */ for (auto const& actor : simix_global->actors_that_ran) { - if (actor->simcall.call_ != SIMCALL_NONE) { + if (actor->simcall_.call_ != SIMCALL_NONE) { actor->simcall_handle(0); } }