-/* Copyright (c) 2004-2021. The SimGrid Team.
+/* Copyright (c) 2004-2022. The SimGrid Team.
* All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
auto* group = new simgrid::smpi::Group(size_);
comm_world_ = new simgrid::smpi::Comm(group, nullptr, false, -1);
universe_size += max_no_processes;
- bar_ = std::make_shared<s4u::Barrier>(size_);
+ bar_ = s4u::Barrier::create(size_);
}
- std::shared_ptr<s4u::Barrier> bar_;
+ s4u::BarrierPtr bar_;
unsigned int size_;
unsigned int finalized_ranks_ = 0;
MPI_Comm comm_world_;
if (code != nullptr) // When started with smpirun, we will not execute a function
simgrid::s4u::Engine::get_instance()->register_function(name, code);
- Instance instance(num_processes);
-
- smpi_instances.insert(std::pair<std::string, Instance>(name, instance));
+ smpi_instances.try_emplace(name, num_processes);
}
void smpi_deployment_register_process(const std::string& instance_id, int rank, const simgrid::s4u::Actor* actor)