A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
don't give the properties to the Link constructor either
[simgrid.git]
/
src
/
surf
/
VirtualMachineImpl.hpp
diff --git
a/src/surf/VirtualMachineImpl.hpp
b/src/surf/VirtualMachineImpl.hpp
index
99faa0b
..
8a8cc68
100644
(file)
--- a/
src/surf/VirtualMachineImpl.hpp
+++ b/
src/surf/VirtualMachineImpl.hpp
@@
-56,7
+56,7
@@
extern XBT_PRIVATE simgrid::xbt::signal<void(simgrid::surf::VirtualMachineImpl*)
*/
class VirtualMachineImpl : public HostImpl {
public:
*/
class VirtualMachineImpl : public HostImpl {
public:
- VirtualMachineImpl(s4u::Host* piface, s4u::Host* host);
+
explicit
VirtualMachineImpl(s4u::Host* piface, s4u::Host* host);
~VirtualMachineImpl();
/** @brief Suspend the VM */
~VirtualMachineImpl();
/** @brief Suspend the VM */
@@
-72,13
+72,16
@@
public:
virtual void restore();
/** @brief Migrate the VM to the destination host */
virtual void restore();
/** @brief Migrate the VM to the destination host */
- virtual void migrate(s
g_host_t dest_PM
);
+ virtual void migrate(s
4u::Host* dest
);
/** @brief Get the physical machine hosting the VM */
/** @brief Get the physical machine hosting the VM */
- s
g_host_t
getPm();
+ s
4u::Host*
getPm();
virtual void setBound(double bound);
virtual void setBound(double bound);
+ void getParams(vm_params_t params);
+ void setParams(vm_params_t params);
+
/* The vm object of the lower layer */
CpuAction* action_ = nullptr;
/* The vm object of the lower layer */
CpuAction* action_ = nullptr;
@@
-90,6
+93,9
@@
public:
void setState(e_surf_vm_state_t state);
static std::deque<VirtualMachineImpl*> allVms_;
void setState(e_surf_vm_state_t state);
static std::deque<VirtualMachineImpl*> allVms_;
+private:
+ s_vm_params_t params_;
+
protected:
e_surf_vm_state_t vmState_ = SURF_VM_STATE_CREATED;
};
protected:
e_surf_vm_state_t vmState_ = SURF_VM_STATE_CREATED;
};
@@
-103,13
+109,6
@@
protected:
*/
class VMModel : public HostModel {
public:
*/
class VMModel : public HostModel {
public:
- /**
- * @brief Create a new VM
- *
- * @param name The name of the new VM
- * @param host_PM The real machine hosting the VM
- */
- s4u::Host* createVM(const char* name, sg_host_t host_PM);
void adjustWeightOfDummyCpuActions() override{};
double nextOccuringEvent(double now) override;
void adjustWeightOfDummyCpuActions() override{};
double nextOccuringEvent(double now) override;