Loading [MathJax]/extensions/TeX/AMSsymbols.js
PSCF v1.2
MpiLogger.h
1#ifdef UTIL_MPI
2#ifndef UTIL_MPI_LOGGER_H
3#define UTIL_MPI_LOGGER_H
4
5/*
6* Util Package - C++ Utilities for Scientific Computation
7*
8* Copyright 2010 - 2017, The Regents of the University of Minnesota
9* Distributed under the terms of the GNU General Public License.
10*/
11
12#include <util/global.h>
13
14#include <iostream>
15#include <string>
16
17namespace Util
18{
19
40 {
41
42 public:
43
47 MpiLogger(MPI::Intracomm& comm = MPI::COMM_WORLD);
48
52 void begin();
53
57 void end();
58
59
60 private:
61
63 MPI::Intracomm* communicatorPtr_;
64
66 int rank_;
67
69 int size_;
70
71 };
72
73}
74
75#endif
76#endif
Allows information from every processor in a communicator, to be output in rank sequence.
Definition MpiLogger.h:40
void end()
End logging block.
Definition MpiLogger.cpp:42
void begin()
Begin logging block.
Definition MpiLogger.cpp:26
MpiLogger(MPI::Intracomm &comm=MPI::COMM_WORLD)
Constructor.
Definition MpiLogger.cpp:18
File containing preprocessor macros for error handling.
Utility classes for scientific computation.