mc_stats_pair_t mc_stats_pair = NULL;
xbt_fifo_t mc_stack_liveness = NULL;
-mc_snapshot_t initial_snapshot_liveness = NULL;
+mc_global_t initial_state_liveness = NULL;
int compare;
/* Local */
XBT_DEBUG("**** Begin Replay ****");
/* Restore the initial state */
- MC_restore_snapshot(initial_snapshot_liveness);
+ MC_restore_snapshot(initial_state_liveness->initial_snapshot);
/* At the moment of taking the snapshot the raw heap was set, so restoring
* it will set it back again, we have to unset it to continue */
+
MC_UNSET_RAW_MEM;
if(all_stack){
successors = xbt_dynar_new(sizeof(mc_pair_stateless_t), NULL);
/* Save the initial state */
- initial_snapshot_liveness = MC_take_snapshot_liveness();
+ initial_state_liveness = xbt_new0(s_mc_global_t, 1);
+ initial_state_liveness->initial_snapshot = MC_take_snapshot_liveness();
MC_UNSET_RAW_MEM;
MC_UNSET_RAW_MEM;
if(cursor != 0){
- MC_restore_snapshot(initial_snapshot_liveness);
+ MC_restore_snapshot(initial_state_liveness->initial_snapshot);
MC_UNSET_RAW_MEM;
}
set_pair_reached(state);
if(cursor != 0){
- MC_restore_snapshot(initial_snapshot_liveness);
+ MC_restore_snapshot(initial_state_liveness->initial_snapshot);
MC_UNSET_RAW_MEM;
}
void *stack_pointer;
}s_mc_snapshot_stack_t, *mc_snapshot_stack_t;
+typedef struct s_mc_global_t{
+ mc_snapshot_t initial_snapshot;
+}s_mc_global_t, *mc_global_t;
+
void MC_take_snapshot(mc_snapshot_t);
mc_snapshot_t MC_take_snapshot_liveness(void);
void MC_restore_snapshot(mc_snapshot_t);
/********************************** Double-DFS for liveness property**************************************/
extern xbt_fifo_t mc_stack_liveness;
-extern mc_snapshot_t initial_snapshot_liveness;
+extern mc_global_t initial_state_liveness;
extern xbt_automaton_t _mc_property_automaton;
extern int compare;
extern void *start_plt_libsimgrid;