Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
s4u::Host->getLoad() returns the achieved speed in flops/s
[simgrid.git] / include / simgrid / s4u / Exec.hpp
index f24e3a9..b140bdb 100644 (file)
@@ -21,7 +21,7 @@ XBT_PUBLIC_CLASS Exec : public Activity
 public:
   friend void intrusive_ptr_release(simgrid::s4u::Exec * e);
   friend void intrusive_ptr_add_ref(simgrid::s4u::Exec * e);
-  friend Actor; // Factory of Exec
+  friend ExecPtr this_actor::exec_init(double flops_amount);
 
   ~Exec() = default;
 
@@ -31,11 +31,13 @@ public:
   bool test();
 
   ExecPtr setPriority(double priority);
+  ExecPtr setHost(Host * host);
 
-  double getRemains();
+  double getRemains() override;
+  double getRemainingRatio();
 
 private:
-  smx_actor_t runner_  = nullptr;
+  Host* host_          = nullptr;
   double flops_amount_ = 0.0;
   double priority_     = 1.0;