12 const char*
const mpi_thread_support_level[] = {
14 "MPI_THREAD_FUNNELED",
15 "MPI_THREAD_SERIALIZED",
31 MPI_Init_thread(
nullptr,
nullptr, MPI_THREAD_MULTIPLE, &provided);
32 if (provided < MPI_THREAD_MULTIPLE) {
34 <<
"CMSSW requires the " << mpi_thread_support_level[MPI_THREAD_MULTIPLE]
35 <<
" multithreading support level, but the MPI library provides only the " << mpi_thread_support_level[provided]
42 MPI_Comm_size(MPI_COMM_WORLD, &world_size);
43 log <<
"MPI_COMM_WORLD size: " << world_size <<
'\n';
47 MPI_Comm_rank(MPI_COMM_WORLD, &world_rank);
48 log <<
"MPI_COMM_WORLD rank: " << world_rank <<
'\n';
51 char processor_name[MPI_MAX_PROCESSOR_NAME];
53 MPI_Get_processor_name(processor_name, &name_len);
54 log <<
"MPI processor name: " << processor_name <<
'\n';
56 log <<
"The MPI library provides the " << mpi_thread_support_level[provided] <<
" multithreading support level\n";
57 log <<
"MPI successfully initialised";
68 descriptions.
add(
"MPIService", desc);
69 descriptions.
setComment(R
"(This Service provides a common interface to MPI configuration for the CMSSW job.)");
static std::vector< std::string > checklist log
#define DEFINE_FWK_SERVICE_MAKER(concrete, maker)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
void setComment(std::string const &value)
MPIService(edm::ParameterSet const &config)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
tuple config
parse the configuration file