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
finish snake_casing resource::Action
[simgrid.git]
/
src
/
plugins
/
vm
/
VirtualMachineImpl.cpp
diff --git
a/src/plugins/vm/VirtualMachineImpl.cpp
b/src/plugins/vm/VirtualMachineImpl.cpp
index
9ba6c33
..
da17d4a
100644
(file)
--- a/
src/plugins/vm/VirtualMachineImpl.cpp
+++ b/
src/plugins/vm/VirtualMachineImpl.cpp
@@
-1,5
+1,4
@@
-/* Copyright (c) 2013-2017. The SimGrid Team.
- * All rights reserved. */
+/* Copyright (c) 2013-2018. The SimGrid Team. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
@@
-54,7
+53,7
@@
static void hostStateChange(s4u::Host& host)
if (vm->getPm() == &host)
trash.push_back(vm);
for (s4u::VirtualMachine* vm : trash)
if (vm->getPm() == &host)
trash.push_back(vm);
for (s4u::VirtualMachine* vm : trash)
- vm->
pimpl_vm_->shutdown(SIMIX_process_self()
);
+ vm->
shutdown(
);
}
}
VMModel::VMModel()
}
}
VMModel::VMModel()
@@
-93,12
+92,12
@@
double VMModel::nextOccuringEvent(double now)
surf::Cpu* cpu = ws_vm->pimpl_cpu;
xbt_assert(cpu, "cpu-less host");
surf::Cpu* cpu = ws_vm->pimpl_cpu;
xbt_assert(cpu, "cpu-less host");
- double solved_value = ws_vm->
pimpl_vm_
->action_->getVariable()->get_value(); // this is X1 in comment above, what
+ double solved_value = ws_vm->
getImpl()
->action_->getVariable()->get_value(); // this is X1 in comment above, what
// this VM got in the sharing on the PM
// this VM got in the sharing on the PM
- XBT_DEBUG("assign %f to vm %s @ pm %s", solved_value, ws_vm->getCname(), ws_vm->
pimpl_vm_->
getPm()->getCname());
+ XBT_DEBUG("assign %f to vm %s @ pm %s", solved_value, ws_vm->getCname(), ws_vm->getPm()->getCname());
xbt_assert(cpu->model() == surf_cpu_model_vm);
xbt_assert(cpu->model() == surf_cpu_model_vm);
-
lmm_system_t
vcpu_system = cpu->model()->getMaxminSystem();
+
kernel::lmm::System*
vcpu_system = cpu->model()->getMaxminSystem();
vcpu_system->update_constraint_bound(cpu->constraint(), virt_overhead * solved_value);
}
vcpu_system->update_constraint_bound(cpu->constraint(), virt_overhead * solved_value);
}
@@
-260,14
+259,14
@@
void VirtualMachineImpl::setPm(s4u::Host* destination)
surf::CpuAction* new_cpu_action =
static_cast<surf::CpuAction*>(destination->pimpl_cpu->execution_start(0, this->coreAmount_));
surf::CpuAction* new_cpu_action =
static_cast<surf::CpuAction*>(destination->pimpl_cpu->execution_start(0, this->coreAmount_));
- if (action_->get
RemainsNoU
pdate() > 0)
- XBT_CRITICAL("FIXME: need copy the state(?), %f", action_->get
RemainsNoU
pdate());
+ if (action_->get
_remains_no_u
pdate() > 0)
+ XBT_CRITICAL("FIXME: need copy the state(?), %f", action_->get
_remains_no_u
pdate());
/* keep the bound value of the cpu action of the VM. */
/* keep the bound value of the cpu action of the VM. */
- double old_bound = action_->get
B
ound();
+ double old_bound = action_->get
_b
ound();
if (old_bound > 0) {
XBT_DEBUG("migrate VM(%s): set bound (%f) at %s", vm_name, old_bound, pm_name_dst);
if (old_bound > 0) {
XBT_DEBUG("migrate VM(%s): set bound (%f) at %s", vm_name, old_bound, pm_name_dst);
- new_cpu_action->set
B
ound(old_bound);
+ new_cpu_action->set
_b
ound(old_bound);
}
XBT_ATTRIB_UNUSED int ret = action_->unref();
}
XBT_ATTRIB_UNUSED int ret = action_->unref();
@@
-280,18
+279,8
@@
void VirtualMachineImpl::setPm(s4u::Host* destination)
void VirtualMachineImpl::setBound(double bound)
{
void VirtualMachineImpl::setBound(double bound)
{
- action_->set
B
ound(bound);
+ action_->set
_b
ound(bound);
}
}
-void VirtualMachineImpl::getParams(vm_params_t params)
-{
- *params = params_;
-}
-
-void VirtualMachineImpl::setParams(vm_params_t params)
-{
- /* may check something here. */
- params_ = *params;
-}
}
}
}
}