23 #ifndef OMPI_MPI_ERRCODE_H
24 #define OMPI_MPI_ERRCODE_H
26 #include "ompi_config.h"
46 char errstring[MPI_MAX_ERROR_STRING];
51 OMPI_DECLSPEC
extern int ompi_mpi_errcode_lastused;
52 OMPI_DECLSPEC
extern int ompi_mpi_errcode_lastpredefined;
61 if ( errcode >= 0 && errcode <= ompi_mpi_errcode_lastused )
77 if ( err->code != MPI_UNDEFINED ) {
81 return ompi_err_unknown.cls;
84 static inline int ompi_mpi_errcode_is_predefined (
int errcode )
86 if ( errcode >= 0 && errcode <= ompi_mpi_errcode_lastpredefined )
92 static inline int ompi_mpi_errnum_is_class (
int errnum )
96 if ( errnum <= ompi_mpi_errcode_lastpredefined ) {
104 if ( MPI_UNDEFINED == err->code) {
126 return err->errstring;
128 return "Unknown error (this should not happen!)";
dynamic pointer array
Definition: opal_pointer_array.h:45
static char * ompi_mpi_errnum_get_string(int errnum)
Return the error string.
Definition: errcode.h:118
static void * opal_pointer_array_get_item(opal_pointer_array_t *table, int element_index)
Get the value of an element in array.
Definition: opal_pointer_array.h:125
See opal_bitmap.h for an explanation of why there is a split between OPAL and ORTE for this generic c...
Back-end type for MPI error codes.
Definition: errcode.h:42
int ompi_mpi_errnum_add_string(int errnum, char *string, int len)
Add an error string to an error code.
Definition: errcode.c:298
int ompi_mpi_errcode_add(int errclass)
Add an error code.
Definition: errcode.c:273
static bool ompi_mpi_errcode_is_invalid(int errcode)
Check for a valid error code.
Definition: errcode.h:59
Base object.
Definition: opal_object.h:182
int ompi_mpi_errcode_init(void)
Initialize the error codes.
Definition: errcode.c:114
int ompi_mpi_errcode_finalize(void)
Finalize the error codes.
Definition: errcode.c:196
A simple C-language object-oriented system with single inheritance and ownership-based memory managem...
static int ompi_mpi_errcode_get_class(int errcode)
Return the error class.
Definition: errcode.h:70
int ompi_mpi_errclass_add(void)
Add an error class.
Definition: errcode.c:286