return heap_bytes_used;
}
-void Api::restore_state(const simgrid::mc::Snapshot* system_state) const
-{
- system_state->restore(&mc_model_checker->get_remote_process());
-}
-
bool Api::snapshot_equal(const Snapshot* s1, const Snapshot* s2) const
{
return simgrid::mc::snapshot_equal(s1, s2);
// REMOTE APIs
std::size_t get_remote_heap_bytes() const;
- // STATE APIs
- void restore_state(const Snapshot* system_state) const;
-
// SNAPSHOT APIs
bool snapshot_equal(const Snapshot* s1, const Snapshot* s2) const;
simgrid::mc::Snapshot* take_snapshot(long num_state) const;
/* If asked to rollback on a state that has a snapshot, restore it */
State* last_state = stack_.back().get();
if (const auto* system_state = last_state->get_system_state()) {
- Api::get().restore_state(system_state);
+ system_state->restore(&get_remote_app().get_remote_process());
on_restore_system_state_signal(last_state, get_remote_app());
return;
}
if (_sg_mc_checkpoint > 0) {
const Pair* pair = exploration_stack_.back().get();
if (const auto* system_state = pair->app_state_->get_system_state()) {
- Api::get().restore_state(system_state);
+ system_state->restore(&get_remote_app().get_remote_process());
return;
}
}