&& (req = MC_state_get_request(state, &value))
&& (visited_state == NULL)) {
- /* Debug information */
- if (XBT_LOG_ISENABLED(mc_comm_determinism, xbt_log_priority_debug)) {
- req_str = MC_request_to_string(req, value);
- XBT_DEBUG("Execute: %s", req_str);
- xbt_free(req_str);
- }
+ MC_LOG_REQUEST(mc_comm_determinism, req, value);
- MC_SET_MC_HEAP;
- if (dot_output != NULL)
+ if (dot_output != NULL) {
+ MC_SET_MC_HEAP;
req_str = MC_request_get_dot_output(req, value);
- MC_SET_STD_HEAP;
+ MC_SET_STD_HEAP;
+ }
MC_state_set_executed_request(state, req, value);
mc_stats->executed_transitions++;
initial_pair->search_cycle = 0;
xbt_fifo_unshift(mc_stack, initial_pair);
-
+
MC_SET_STD_HEAP;
MC_modelcheck_liveness();
int value;
smx_simcall_t req = NULL;
- char *req_str;
xbt_automaton_transition_t transition_succ;
unsigned int cursor = 0;
}
MC_SET_STD_HEAP;
- /* Debug information */
- if (XBT_LOG_ISENABLED(mc_liveness, xbt_log_priority_debug)) {
- req_str = MC_request_to_string(req, value);
- XBT_DEBUG("Execute: %s", req_str);
- xbt_free(req_str);
- }
+ MC_LOG_REQUEST(mc_liveness, req, value);
MC_SET_MC_HEAP;
if (dot_output != NULL) {
return *(void**) mc_snapshot_read_region(addr, region, &res, sizeof(void*));
}
+#define MC_LOG_REQUEST(log, req, value) \
+ if (XBT_LOG_ISENABLED(log, xbt_log_priority_debug)) { \
+ char* req_str = MC_request_to_string(req, value); \
+ XBT_DEBUG("Execute: %s", req_str); \
+ xbt_free(req_str); \
+ }
+
SG_END_DECL()
#endif
if (xbt_fifo_size(mc_stack) <= _sg_mc_max_depth && !user_max_depth_reached
&& (req = MC_state_get_request(state, &value)) && visited_state == NULL) {
- /* Debug information */
- if (XBT_LOG_ISENABLED(mc_safety, xbt_log_priority_debug)) {
- req_str = MC_request_to_string(req, value);
- XBT_DEBUG("Execute: %s", req_str);
- xbt_free(req_str);
- }
+ MC_LOG_REQUEST(mc_safety, req, value);
- MC_SET_MC_HEAP;
- if (dot_output != NULL)
+ if (dot_output != NULL) {
+ MC_SET_MC_HEAP;
req_str = MC_request_get_dot_output(req, value);
- MC_SET_STD_HEAP;
+ MC_SET_STD_HEAP;
+ }
MC_state_set_executed_request(state, req, value);
mc_stats->executed_transitions++;