XBT_INFO("*********************************************************");
XBT_INFO("%s", send_diff.c_str());
exploration_.log_state();
- exploration_.system_exit(ExitStatus::NON_DETERMINISM);
+ throw McError(ExitStatus::NON_DETERMINISM);
} else if (_sg_mc_comms_determinism && (not send_deterministic && not recv_deterministic)) {
XBT_INFO("****************************************************");
XBT_INFO("***** Non-deterministic communications pattern *****");
if (not recv_diff.empty())
XBT_INFO("%s", recv_diff.c_str());
exploration_.log_state();
- exploration_.system_exit(ExitStatus::NON_DETERMINISM);
+ throw McError(ExitStatus::NON_DETERMINISM);
}
}
}
XBT_INFO("Stack trace not shown because there is no memory introspection.");
}
- system_exit(ExitStatus::PROGRAM_CRASH);
+ throw McError(ExitStatus::PROGRAM_CRASH);
}
XBT_ATTRIB_NORETURN void Exploration::report_assertion_failure()
{
"--cfg=model-check/replay:'%s'",
get_record_trace().to_string().c_str());
log_state();
- system_exit(ExitStatus::SAFETY);
-}
-
-void Exploration::system_exit(ExitStatus status) const
-{
- throw McError(status);
+ throw McError(ExitStatus::SAFETY);
}
}; // namespace simgrid::mc
/** Produce an error message indicating that a property was violated */
XBT_ATTRIB_NORETURN void report_assertion_failure();
- /** Kill the application and the model-checker (which exits with `status`)*/
- XBT_ATTRIB_NORETURN void system_exit(ExitStatus status) const;
-
/* These methods are callbacks called by the model-checking engine
* to get and display information about the current state of the
* model-checking algorithm: */