Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
More doc for SMPI
[simgrid.git] / teshsuite / s4u / monkey-masterworkers / monkey-masterworkers.cpp
index 2775b84..4a4fca3 100644 (file)
@@ -9,7 +9,7 @@
  * It is not written to be pleasant to read, but instead to resist the aggressions of the monkey:
  * - Workers keep going until after a global variable `todo` reaches 0.
  * - The master is a daemon that just sends infinitely tasks
- *   (simgrid simulations stop as soon as all non-daemon actors are done).
+ *   (SimGrid simulations stop as soon as all non-daemon actors are done).
  * - The platform is created programmatically to remove path issues and control the problem size.
  *
  * Command-line configuration items:
@@ -114,8 +114,8 @@ int main(int argc, char* argv[])
   for (int i = 1; i < cfg_host_count; i++) {
     auto hostname = "lilibeth " + std::to_string(i);
     auto* host    = rootzone->create_host(hostname, 1e9);
-    sg4::LinkInRoute link(rootzone->create_link(hostname, "1MBps")->set_latency("24us")->seal());
-    rootzone->add_route(master_host->get_netpoint(), host->get_netpoint(), nullptr, nullptr, {link}, true);
+    auto* link    = rootzone->create_link(hostname, "1MBps")->set_latency("24us")->seal();
+    rootzone->add_route(master_host, host, {link});
     worker_hosts.push_back(host);
   }
   rootzone->seal();