- Cpu(){};
- Cpu(CpuModelPtr model, const char* name, xbt_dict_t properties, int core, double powerPeak, double powerScale)
- : Resource(model, name, properties), m_core(core), m_powerPeak(powerPeak), m_powerScale(powerScale)
- {};
- virtual ActionPtr execute(double size)=0;
- virtual ActionPtr sleep(double duration)=0;
+ /**
+ * @brief Cpu constructor
+ *
+ * @param model The CpuModel associated to this Cpu
+ * @param host The host in which this Cpu should be plugged
+ * @param constraint The lmm constraint associated to this Cpu if it is part of a LMM component
+ * @param speedPerPstate Processor speed (in flop per second) for each pstate
+ * @param core The number of core of this Cpu
+ */
+ Cpu(simgrid::surf::Model *model, simgrid::s4u::Host *host, lmm_constraint_t constraint, xbt_dynar_t speedPerPstate, int core);
+
+ /**
+ * @brief Cpu constructor
+ *
+ * @param model The CpuModel associated to this Cpu
+ * @param host The host in which this Cpu should be plugged
+ * @param speedPerPstate Processor speed (in flop per second) for each pstate
+ * @param core The number of core of this Cpu
+ */
+ Cpu(simgrid::surf::Model *model, simgrid::s4u::Host *host, xbt_dynar_t speedPerPstate, int core);
+
+ ~Cpu();
+
+ /**
+ * @brief Execute some quantity of computation
+ *
+ * @param size The value of the processing amount (in flop) needed to process
+ * @return The CpuAction corresponding to the processing
+ */
+ virtual simgrid::surf::Action *execution_start(double size)=0;
+
+ /**
+ * @brief Make a process sleep for duration (in seconds)
+ *
+ * @param duration The number of seconds to sleep
+ * @return The CpuAction corresponding to the sleeping
+ */
+ virtual simgrid::surf::Action *sleep(double duration)=0;
+
+ /** @brief Get the amount of cores */