Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Move some content of surf_interface to a new math_utils.h
[simgrid.git] / src / kernel / resource / CpuImpl.hpp
index 28b1c8772fc9abf077d503ed3432497bccbe5a21..3456bfa1338001f75ad183abe335b96eca0968af 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2004-2021. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2004-2023. 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. */
@@ -13,9 +13,7 @@
 
 #include <list>
 
-namespace simgrid {
-namespace kernel {
-namespace resource {
+namespace simgrid::kernel::resource {
 
 /***********
  * Classes *
@@ -79,6 +77,8 @@ public:
   CpuImpl* set_core_count(int core_count);
   virtual int get_core_count() const { return core_count_; }
 
+  bool is_used() const override { return true; }
+
   void seal() override;
 
   /** @brief Get a forecast of the speed (in flops/s) if the load were as provided.
@@ -190,8 +190,6 @@ public:
   void suspend() override;
   void resume() override;
 };
-} // namespace resource
-} // namespace kernel
-} // namespace simgrid
+} // namespace simgrid::kernel::resource
 
 #endif /* CPU_IMPL_HPP_ */