#include "mc_private.h"
#include "mc_unw.h"
#include "mc_smx.h"
+#include "mcer_ignore.h"
#endif
#include "mc_record.h"
#include "mc_protocol.h"
/* Init parmap */
//parmap = xbt_parmap_mc_new(xbt_os_get_numcores(), XBT_PARMAP_DEFAULT);
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
if (_sg_mc_visited > 0 || _sg_mc_liveness || _sg_mc_termination || mc_mode == MC_MODE_SERVER) {
/* Ignore some variables from xbt/ex.h used by exception e for stacks comparison */
MC_ignore_local_variable("start_time", "*");
/* Main MC state: */
- MC_ignore_global_variable("mc_model_checker");
- MC_ignore_global_variable("initial_communications_pattern");
- MC_ignore_global_variable("incomplete_communications_pattern");
- MC_ignore_global_variable("nb_comm_pattern");
+ MCer_ignore_global_variable("mc_model_checker");
+ MCer_ignore_global_variable("initial_communications_pattern");
+ MCer_ignore_global_variable("incomplete_communications_pattern");
+ MCer_ignore_global_variable("nb_comm_pattern");
/* MC __thread variables: */
- MC_ignore_global_variable("mc_diff_info");
- MC_ignore_global_variable("mc_comp_times");
- MC_ignore_global_variable("mc_snapshot_comparison_time");
+ MCer_ignore_global_variable("mc_diff_info");
+ MCer_ignore_global_variable("mc_comp_times");
+ MCer_ignore_global_variable("mc_snapshot_comparison_time");
/* This MC state is used in MC replay as well: */
- MC_ignore_global_variable("mc_time");
+ MCer_ignore_global_variable("mc_time");
/* Static variable used for tracing */
- MC_ignore_global_variable("counter");
+ MCer_ignore_global_variable("counter");
/* SIMIX */
- MC_ignore_global_variable("smx_total_comms");
+ MCer_ignore_global_variable("smx_total_comms");
if (mc_mode == MC_MODE_CLIENT) {
/* Those requests are handled on the client side and propagated by message
MC_restore_snapshot(state->system_state);
if(_sg_mc_comms_determinism || _sg_mc_send_determinism)
MC_restore_communications_pattern(state);
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
return;
}
}
MC_restore_snapshot(initial_global_state->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_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
start_item = xbt_fifo_get_last_item(stack);
- MC_SET_MC_HEAP;
+ mmalloc_set_current_heap(mc_heap);
if (_sg_mc_comms_determinism || _sg_mc_send_determinism) {
// int n = xbt_dynar_length(incomplete_communications_pattern);
}
}
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
/* Traverse the stack from the state at position start and re-execute the transitions */
for (item = start_item;
MC_simcall_handle(req, value);
- MC_SET_MC_HEAP;
+ mmalloc_set_current_heap(mc_heap);
if (_sg_mc_comms_determinism || _sg_mc_send_determinism)
MC_handle_comm_pattern(call, req, value, NULL, 1);
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
MC_wait_for_requests();
pair = (mc_pair_t) xbt_fifo_get_item_content(item);
if(pair->graph_state->system_state){
MC_restore_snapshot(pair->graph_state->system_state);
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
return;
}
}
/* 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 */
if (!initial_global_state->raw_mem_set)
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
/* Traverse the stack from the initial state and re-execute the transitions */
for (item = xbt_fifo_get_last_item(stack);
XBT_DEBUG("**** End Replay ****");
if (initial_global_state->raw_mem_set)
- MC_SET_MC_HEAP;
+ mmalloc_set_current_heap(mc_heap);
else
- MC_SET_STD_HEAP;
+ mmalloc_set_current_heap(std_heap);
}
mc_state_t state;
- MC_SET_MC_HEAP;
+ mmalloc_set_current_heap(mc_heap);
while ((state = (mc_state_t) xbt_fifo_pop(stack)) != NULL)
MC_state_delete(state, !state->in_visited_states ? 1 : 0);
mmalloc_set_current_heap(heap);