delete speed_integrated_trace_;
}
+void CpuTi::turn_off()
+{
+ /* Skip CpuImpl::turn_off() that marks the actions as failing, as it seems to be done otherwise in CPU TI.
+ * So, just avoid the segfault for now.
+ *
+ * TODO: a proper solution would be to understand and adapt the way actions are marked FAILED in here,
+ * and adapt it to align with the other resources. */
+ Resource::turn_off();
+}
+
CpuImpl* CpuTi::set_speed_profile(kernel::profile::Profile* profile)
{
delete speed_integrated_trace_;
}
} else {
get_iface()->turn_off();
- double date = EngineImpl::get_clock();
/* put all action running on cpu to failed */
+ double now = EngineImpl::get_clock();
for (CpuTiAction& action : action_set_) {
if (action.get_state() == Action::State::INITED || action.get_state() == Action::State::STARTED ||
action.get_state() == Action::State::IGNORED) {
- action.set_finish_time(date);
+ action.set_finish_time(now);
action.set_state(Action::State::FAILED);
get_model()->get_action_heap().remove(&action);
}