X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/8230f9204f084386397755b97f8728bd12ff3848..120df14075aaab1a27d234cd170cff2b4f7df071:/src/smpi/internals/instr_smpi.cpp diff --git a/src/smpi/internals/instr_smpi.cpp b/src/smpi/internals/instr_smpi.cpp index 57ac211726..504f43c835 100644 --- a/src/smpi/internals/instr_smpi.cpp +++ b/src/smpi/internals/instr_smpi.cpp @@ -187,7 +187,7 @@ void TRACE_smpi_init(int rank) TRACE_smpi_setup_container(rank, sg_host_self()); #if HAVE_PAPI - container_t container = simgrid::instr::Container::by_name(str); + container_t container = smpi_container(rank); papi_counter_t counters = smpi_process()->papi_counters(); for (auto const& it : counters) { @@ -195,9 +195,7 @@ void TRACE_smpi_init(int rank) * Check whether this variable already exists or not. Otherwise, it will be created * multiple times but only the last one would be used... */ - if (s_type::getOrNull(it.first.c_str(), container->type_) == nullptr) { - Type::variableNew(it.first.c_str(), "", container->type_); - } + container->type_->by_name_or_create(it.first, ""); } #endif }