source: src/comm/mpi/error_handler.cpp@ 51e793

Last change on this file since 51e793 was ac6d04, checked in by Julian Iseringhausen <isering@…>, 14 years ago

Merge recent changes of the vmg library into ScaFaCos.

Includes a fix for the communication problems on Jugene.

git-svn-id: https://svn.version.fz-juelich.de/scafacos/trunk@1666 5161e1c8-67bf-11de-9fd5-51895aff932f

  • Property mode set to 100644
File size: 720 bytes
Line 
1/**
2 * @file error_handler.cpp
3 * @author Julian Iseringhausen <isering@ins.uni-bonn.de>
4 * @date Mon Nov 21 13:27:22 2011
5 *
6 * @brief Convert MPI errors to C++ exceptions. Used to be
7 * able to call a debugger when MPI crashes
8 * internally.
9 *
10 */
11
12#ifdef HAVE_CONFIG_H
13#include <config.h>
14#endif
15
16#ifdef HAVE_MPI
17
18#include <mpi.h>
19#ifdef HAVE_MARMOT
20#include <enhancempicalls.h>
21#include <sourceinfompicalls.h>
22#endif
23
24#include "comm/mpi/error_handler.hpp"
25
26void VMG::MPI::ConvertToException(MPI_Comm* comm, int* err, ...)
27{
28 char error_string[MPI_MAX_ERROR_STRING];
29 int resultlen;
30 MPI_Error_string(*err, error_string, &resultlen);
31 throw Exception(error_string);
32}
33
34#endif /* HAVE_MPI */
Note: See TracBrowser for help on using the repository browser.