}
void smpi_execute_flops(double flops) {
+ xbt_assert(flops >= 0, "You're trying to execute a negative amount of flops (%f)!", flops);
XBT_DEBUG("Handle real computation time: %f flops", flops);
smx_activity_t action = simcall_execution_start("computation", flops, 1, 0, smpi_process()->process()->getHost());
simcall_set_category (action, TRACE_internal_smpi_get_category());
simcall_execution_wait(action);
- smpi_switch_data_segment(simgrid::s4u::Actor::self()->getPid());
+ smpi_switch_data_segment(simgrid::s4u::Actor::self());
}
void smpi_execute(double duration)
void smpi_bench_begin()
{
if (smpi_privatize_global_variables == SMPI_PRIVATIZE_MMAP) {
- smpi_switch_data_segment(simgrid::s4u::Actor::self()->getPid());
+ smpi_switch_data_segment(simgrid::s4u::Actor::self());
}
if (MC_is_active() || MC_record_replay_is_active())
data.benching = false;
}
-extern "C" { /** These functions will be called from the user code **/
smpi_trace_call_location_t* smpi_trace_get_call_location()
{
return smpi_process()->call_location();
{
smpi_trace_set_call_location(file, *line);
}
-}
void smpi_bench_destroy()
{