-/* Copyright (c) 2010-2022. The SimGrid Team. All rights reserved. */
+/* Copyright (c) 2010-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. */
long communication_cost = std::stol(args[3]);
size_t workers_count = args.size() - 4;
const auto& my_host = sg4::this_actor::get_host()->get_name();
- auto mailbox = sg4::Mailbox::by_name("master_mailbox");
+ auto* mailbox = sg4::Mailbox::by_name("master_mailbox");
XBT_DEBUG("Got %zu workers and %ld tasks to process", workers_count, tasks_count);
xbt_assert(args.size() == 1, "The worker expects no argument");
const auto& my_host = sg4::this_actor::get_host()->get_name();
- auto mailbox = sg4::Mailbox::by_name("master_mailbox");
+ auto* mailbox = sg4::Mailbox::by_name("master_mailbox");
simgrid::instr::set_host_variable(my_host, "is_worker", 1);
simgrid::instr::set_host_variable(my_host, "task_computation", 0);
XBT_DEBUG("Simulation is over");
- const auto& categories = simgrid::instr::get_tracing_categories();
- if (not categories.empty()) {
+ if (const auto& categories = simgrid::instr::get_tracing_categories(); not categories.empty()) {
XBT_INFO("Declared tracing categories:");
for (const auto& category : categories)
XBT_INFO("%s", category.c_str());
}
- const auto& marks = simgrid::instr::get_marks();
- if (not marks.empty()) {
+ if (const auto& marks = simgrid::instr::get_marks(); not marks.empty()) {
XBT_INFO("Declared marks:");
for (const auto& mark : marks)
XBT_INFO("%s", mark.c_str());