void wait_for_requests()
{
#if SIMGRID_HAVE_MC
- xbt_assert(mc_model_checker == nullptr);
+ xbt_assert(mc_model_checker == nullptr, "This must be called from the client");
#endif
smx_actor_t process;
- smx_simcall_t req;
unsigned int iter;
while (not xbt_dynar_is_empty(simix_global->process_to_run)) {
SIMIX_process_runall();
xbt_dynar_foreach(simix_global->process_that_ran, iter, process) {
- req = &process->simcall;
+ smx_simcall_t req = &process->simcall;
if (req->call != SIMCALL_NONE && not simgrid::mc::request_is_visible(req))
SIMIX_simcall_handle(req, 0);
}
}
}
+/* This is the list of requests that are visible from the checker algorithm.
+ * Any other requests are handled right away on the application side.
+ */
bool request_is_visible(smx_simcall_t req)
{
+ xbt_assert(mc_model_checker == nullptr, "This should be called from the client side");
return req->call == SIMCALL_COMM_ISEND
|| req->call == SIMCALL_COMM_IRECV
|| req->call == SIMCALL_COMM_WAIT