namespace simgrid {
namespace simix {
-simgrid::xbt::signal<void()> onDeadlock;
-
simgrid::config::Flag<double> breakpoint{"simix/breakpoint",
"When non-negative, raise a SIGTRAP after given (simulated) time", -1.0};
}
}
-static std::function<void()> maestro_code;
+static simgrid::simix::ActorCode maestro_code;
void SIMIX_set_maestro(void (*code)(void*), void* data)
{
#ifdef _WIN32
do {
XBT_DEBUG("New Schedule Round; size(queue)=%zu", simix_global->process_to_run.size());
- if (simgrid::simix::breakpoint >= 0.0 && time >= simgrid::simix::breakpoint) {
+ if (simgrid::simix::breakpoint >= 0.0 && surf_get_clock() >= simgrid::simix::breakpoint) {
XBT_DEBUG("Breakpoint reached (%g)", simgrid::simix::breakpoint.get());
simgrid::simix::breakpoint = -1.0;
#ifdef SIGTRAP
XBT_DEBUG("### time %f, #processes %zu, #to_run %zu", time, simix_global->process_list.size(),
simix_global->process_to_run.size());
- if (simix_global->process_to_run.empty() && not simix_global->process_list.empty())
- simgrid::simix::onDeadlock();
-
} while (time > -1.0 || not simix_global->process_to_run.empty());
if (not simix_global->process_list.empty()) {