Skip to content

added Environment for MPI initialization

Praetorius, Simon requested to merge feature/environment into master

This MR replaces the old AMDiS::init() - AMDiS::finalize() pattern with a RAII class Environment, to be instantiated at the begin of the main method, i.e.

int main(int argc, char** argv)
  Environment env(argc, argv);

  // get MPI rank and size from environment after instantiation:
  std::cout << Environment::mpiRank();
  std::cout << Environment::mpiSize(); 

the ``finalize'' is called automatically when env is destructed, i.e. at the end of main().

Edited by Praetorius, Simon

Merge request reports