X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/015e60ae9d53f50a72b7b8ec61d17607aaa5a78c..6cb7d1fc585d47d6dbad8c288e8f275448f8025c:/src/surf/cpu_cas01.cpp diff --git a/src/surf/cpu_cas01.cpp b/src/surf/cpu_cas01.cpp index 163d045799..6d8ca3cc7c 100644 --- a/src/surf/cpu_cas01.cpp +++ b/src/surf/cpu_cas01.cpp @@ -63,10 +63,6 @@ CpuCas01Model::CpuCas01Model() : simgrid::surf::CpuModel() CpuCas01Model::~CpuCas01Model() { - delete maxminSystem_; - maxminSystem_ = nullptr; - delete modifiedSet_; - surf_cpu_model_pm = nullptr; } @@ -160,10 +156,11 @@ void CpuCas01::apply_event(tmgr_trace_event_t event, double value) } /** @brief Start a new execution on this CPU lasting @param size flops and using one core */ -CpuAction *CpuCas01::execution_start(double size) +CpuAction* CpuCas01::execution_start(double size) { return new CpuCas01Action(model(), size, isOff(), speed_.scale * speed_.peak, constraint()); } + CpuAction* CpuCas01::execution_start(double size, int requestedCores) { return new CpuCas01Action(model(), size, isOff(), speed_.scale * speed_.peak, constraint(), requestedCores); @@ -179,7 +176,7 @@ CpuAction *CpuCas01::sleep(double duration) // FIXME: sleep variables should not consume 1.0 in System::expand() action->setMaxDuration(duration); - action->suspended_ = 2; + action->suspended_ = Action::SuspendStates::sleeping; if (duration < 0) { // NO_MAX_DURATION /* Move to the *end* of the corresponding action set. This convention is used to speed up update_resource_state */ simgrid::xbt::intrusive_erase(*action->getStateSet(), *action);