X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/8c416e92254512408c1d0ce729e8d3cf82ec9938..63ebf4be4ca6a243a64c7ded8df9b96a9d28d3ff:/examples/s4u/app-pingpong/s4u-app-pingpong.cpp diff --git a/examples/s4u/app-pingpong/s4u-app-pingpong.cpp b/examples/s4u/app-pingpong/s4u-app-pingpong.cpp index c94df9ccc0..542b1b4175 100644 --- a/examples/s4u/app-pingpong/s4u-app-pingpong.cpp +++ b/examples/s4u/app-pingpong/s4u-app-pingpong.cpp @@ -16,14 +16,14 @@ static void pinger(std::vector args) /* - Do the ping with a 1-Byte task (latency bound) ... */ double* payload = new double(); - *payload = simgrid::s4u::Engine::getClock(); + *payload = simgrid::s4u::Engine::get_clock(); simgrid::s4u::Mailbox::byName(args[0])->put(payload, 1); /* - ... then wait for the (large) pong */ double* sender_time = static_cast(simgrid::s4u::Mailbox::byName(simgrid::s4u::this_actor::get_host()->get_name())->get()); - double communication_time = simgrid::s4u::Engine::getClock() - *sender_time; + double communication_time = simgrid::s4u::Engine::get_clock() - *sender_time; XBT_INFO("Task received : large communication (bandwidth bound)"); XBT_INFO("Pong time (bandwidth bound): %.3f", communication_time); delete sender_time; @@ -39,14 +39,14 @@ static void ponger(std::vector args) /* - Receive the (small) ping first ....*/ double* sender_time = static_cast(simgrid::s4u::Mailbox::byName(simgrid::s4u::this_actor::get_host()->get_name())->get()); - double communication_time = simgrid::s4u::Engine::getClock() - *sender_time; + double communication_time = simgrid::s4u::Engine::get_clock() - *sender_time; XBT_INFO("Task received : small communication (latency bound)"); XBT_INFO(" Ping time (latency bound) %f", communication_time); delete sender_time; /* - ... Then send a 1GB pong back (bandwidth bound) */ double* payload = new double(); - *payload = simgrid::s4u::Engine::getClock(); + *payload = simgrid::s4u::Engine::get_clock(); XBT_INFO("task_bw->data = %.3f", *payload); simgrid::s4u::Mailbox::byName(args[0])->put(payload, 1e9); @@ -68,7 +68,7 @@ int main(int argc, char* argv[]) e.run(); - XBT_INFO("Total simulation time: %.3f", e.getClock()); + XBT_INFO("Total simulation time: %.3f", e.get_clock()); return 0; }