-XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_VisitedState, mc,
- "Logging specific to state equaity detection mechanisms");
-
-namespace simgrid {
-namespace mc {
-
-static int snapshot_compare(simgrid::mc::VisitedState* state1, simgrid::mc::VisitedState* state2)
-{
- simgrid::mc::Snapshot* s1 = state1->system_state.get();
- simgrid::mc::Snapshot* s2 = state2->system_state.get();
- int num1 = state1->num;
- int num2 = state2->num;
- return snapshot_compare(num1, s1, num2, s2);
-}
-
-/**
- * \brief Save the current state
- * \return Snapshot of the current state.
- */
-VisitedState::VisitedState(unsigned long state_number)
-{
- simgrid::mc::Process* process = &(mc_model_checker->process());
- this->heap_bytes_used = mmalloc_get_bytes_used_remote(
- process->get_heap()->heaplimit,
- process->get_malloc_info());
-
- this->nb_processes =
- mc_model_checker->process().simix_processes().size();
-
- this->system_state = simgrid::mc::take_snapshot(state_number);
- this->num = state_number;
- this->other_num = -1;
-}
-
-VisitedState::~VisitedState()
+/** @brief Save the current state */
+VisitedState::VisitedState(unsigned long state_number, unsigned int actor_count)
+ : actor_count_(actor_count), num(state_number)