Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of https://github.com/mpoquet/simgrid
[simgrid.git] / src / plugins / vm / VmHostExt.hpp
1 /* Copyright (c) 2004-2016. The SimGrid Team. All rights reserved.          */
2
3 /* This program is free software; you can redistribute it and/or modify it
4  * under the terms of the license (GNU LGPL) which comes with this package. */
5
6 #include <xbt/base.h>
7
8 #include "src/surf/HostImpl.hpp"
9
10 #ifndef VM_HOST_INFO_HPP_
11 #define VM_HOST_INFO_HPP_
12
13 namespace simgrid {
14 namespace vm {
15 /** @brief Host extension for the VMs */
16 class VmHostExt {
17 public:
18   static simgrid::xbt::Extension<simgrid::s4u::Host, VmHostExt> EXTENSION_ID;
19   virtual ~VmHostExt();
20
21   sg_size_t ramsize = 0;    /* available ramsize (0= not taken into account) */
22   bool overcommit   = true; /* Whether the host allows overcommiting more VM than the avail ramsize allows */
23
24   static void ensureVmExtInstalled();
25 };
26 }
27 }
28
29 #endif /* VM_HOST_INFO_HPP_ */