su2hmc
Loading...
Searching...
No Matches
errorcodes.h File Reference

This header is intended to be a useful reference for error codes and their meanings. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define OPENERROR   10001
 Error opening file.
#define READERROR   10002
 Error reading file.
#define WRITERROR   10003
 Error writing to file.
#define ARGERROR   10004
 Error with argument.
#define OPENWARN   10101
 Minor issue opening file.
#define READWARN   10102
 Minor issue reading file.
#define WRITEWARN   10103
 Minor issue writing to file.
#define ARGWARN   10104
 Minor argument issue.
#define INDTOCOORD   11001
 Issues converting index to coordinates.
#define COORDTOIND   11002
 Issues converting coordinate to index.
#define BOUNDERROR   11003
 Accessing out of bounds element.
#define ARRAYLEN   11004
 Impossible value for array length.
#define CPYERROR   11005
 Copy failed.
#define STRDERROR   11006
 Undefined stride.
#define BOUNDWARN   11103
 Accessing out of bounds element, but not a big enough problem to crash the programme.
#define LIMWARN   11104
 Order of limits (x_min and x_max for example) is reversed.
#define CPYWARN   11105
 Copy failed.
#define NO_MPI_INIT   12001
 Failed to initialise MPI.
#define NO_MPI_RANK   12002
 Failed to get the rank of the process.
#define NO_MPI_SIZE   12003
 Failed to get the number of ranks.
#define SIZEPROC   12004
 Communicator size does not match expected size.
#define NUMELEM   12005
 Failed to evaluate the number of elements.
#define CANTSEND   12006
 Couldn't send to another process.
#define CANTRECV   12007
 Couldn't receive from another process.
#define BROADERR   12008
 Couldn't broadcast to the processes.
#define REDUCERR   12009
 Couldn't carry out a reduction operation.
#define GATHERR   12010
 Couldn't complete a gather operation.
#define DIFNPROC   12101
 Continuation run on different grid size.
#define LAYERROR   13001
 brief Can't access a layer of a halo
#define HALOLIM   13002
 Index goes beyond the halo.
#define DIVZERO   14001
 Division by zero.
#define REUNIERR   14002
 Gauge link reunitarisation failed.
#define CONVERR   14003
 Failed to convert precision correctly.
#define UDPERR   14003
 Up/down partitioning failed.
#define SPHIERR   14004
 Up/down partitioning failed.
#define ITERLIM   14101
 Exceeded max number of iterations.
#define FITWARN   14102
 Fitting function has repeated x value.
#define NOINIT   14201
 Not initialising the lattice.
#define BLOCKERROR   15001
 Error with setting block size.
#define BLOCKWARN   15101
 Warning with block size.
#define BLOCKALERT   15201
 Alert with block size.
#define NOIMPL   16001
 Not implemented.

Detailed Description

This header is intended to be a useful reference for error codes and their meanings.

By placing all the error codes in one file I hope to make it easier to diagnose any potential issues that crop up, and create a logical and consistent labelling system for error codes.

Error codes will take the following format: XXYZZ where XX is the category of code (File Related, Index Related etc.) Y is the severity (0 for error, 1 for warning and more to be added later) ZZ is the identifying code.

Hopefully two digits should be enough to cover all possibilities.

The way I intend the codes to be used is fprintf(stderr, "Error %i in %s: Description of what happened\nExiting...\n\n", CODE, funcname,\ anything else to be printed); It goes without saying that the Exiting bit should only be used if actually exiting the programme and can be replaced with other text. Same with the first word Error for warnings etc.

Definition in file errorcodes.h.

Macro Definition Documentation

◆ ARGERROR

#define ARGERROR   10004

Error with argument.

Definition at line 38 of file errorcodes.h.

◆ ARGWARN

#define ARGWARN   10104

Minor argument issue.

Definition at line 49 of file errorcodes.h.

◆ ARRAYLEN

#define ARRAYLEN   11004

Impossible value for array length.

Definition at line 64 of file errorcodes.h.

◆ BLOCKALERT

#define BLOCKALERT   15201

Alert with block size.

Definition at line 161 of file errorcodes.h.

◆ BLOCKERROR

#define BLOCKERROR   15001

Error with setting block size.

Definition at line 151 of file errorcodes.h.

◆ BLOCKWARN

#define BLOCKWARN   15101

Warning with block size.

Definition at line 156 of file errorcodes.h.

◆ BOUNDERROR

#define BOUNDERROR   11003

Accessing out of bounds element.

Definition at line 62 of file errorcodes.h.

◆ BOUNDWARN

#define BOUNDWARN   11103

Accessing out of bounds element, but not a big enough problem to crash the programme.

Definition at line 73 of file errorcodes.h.

◆ BROADERR

#define BROADERR   12008

Couldn't broadcast to the processes.

Definition at line 99 of file errorcodes.h.

◆ CANTRECV

#define CANTRECV   12007

Couldn't receive from another process.

Definition at line 97 of file errorcodes.h.

◆ CANTSEND

#define CANTSEND   12006

Couldn't send to another process.

Definition at line 95 of file errorcodes.h.

◆ CONVERR

#define CONVERR   14003

Failed to convert precision correctly.

Definition at line 128 of file errorcodes.h.

◆ COORDTOIND

#define COORDTOIND   11002

Issues converting coordinate to index.

Definition at line 60 of file errorcodes.h.

◆ CPYERROR

#define CPYERROR   11005

Copy failed.

Definition at line 66 of file errorcodes.h.

◆ CPYWARN

#define CPYWARN   11105

Copy failed.

Definition at line 77 of file errorcodes.h.

◆ DIFNPROC

#define DIFNPROC   12101

Continuation run on different grid size.

Definition at line 108 of file errorcodes.h.

◆ DIVZERO

#define DIVZERO   14001

Division by zero.

and Maths Errors. Leading digits are 14

Definition at line 124 of file errorcodes.h.

◆ FITWARN

#define FITWARN   14102

Fitting function has repeated x value.

Definition at line 139 of file errorcodes.h.

◆ GATHERR

#define GATHERR   12010

Couldn't complete a gather operation.

Definition at line 103 of file errorcodes.h.

◆ HALOLIM

#define HALOLIM   13002

Index goes beyond the halo.

Definition at line 117 of file errorcodes.h.

◆ INDTOCOORD

#define INDTOCOORD   11001

Issues converting index to coordinates.

Memory Errors.

Leading digits are 11

Definition at line 58 of file errorcodes.h.

◆ ITERLIM

#define ITERLIM   14101

Exceeded max number of iterations.

Definition at line 137 of file errorcodes.h.

◆ LAYERROR

#define LAYERROR   13001

brief Can't access a layer of a halo

Errors. Leading digits are 13

Definition at line 115 of file errorcodes.h.

◆ LIMWARN

#define LIMWARN   11104

Order of limits (x_min and x_max for example) is reversed.

Definition at line 75 of file errorcodes.h.

◆ NO_MPI_INIT

#define NO_MPI_INIT   12001

Failed to initialise MPI.

MPI Errors. Leading digits are 12

Definition at line 85 of file errorcodes.h.

◆ NO_MPI_RANK

#define NO_MPI_RANK   12002

Failed to get the rank of the process.

Definition at line 87 of file errorcodes.h.

◆ NO_MPI_SIZE

#define NO_MPI_SIZE   12003

Failed to get the number of ranks.

Definition at line 89 of file errorcodes.h.

◆ NOIMPL

#define NOIMPL   16001

Not implemented.

errors. Leading digits are 16

Definition at line 165 of file errorcodes.h.

◆ NOINIT

#define NOINIT   14201

Not initialising the lattice.

Definition at line 144 of file errorcodes.h.

◆ NUMELEM

#define NUMELEM   12005

Failed to evaluate the number of elements.

Definition at line 93 of file errorcodes.h.

◆ OPENERROR

#define OPENERROR   10001

Error opening file.

File I/O Errors. Leading digits are 10

Definition at line 32 of file errorcodes.h.

◆ OPENWARN

#define OPENWARN   10101

Minor issue opening file.

Definition at line 43 of file errorcodes.h.

◆ READERROR

#define READERROR   10002

Error reading file.

Definition at line 34 of file errorcodes.h.

◆ READWARN

#define READWARN   10102

Minor issue reading file.

Definition at line 45 of file errorcodes.h.

◆ REDUCERR

#define REDUCERR   12009

Couldn't carry out a reduction operation.

Definition at line 101 of file errorcodes.h.

◆ REUNIERR

#define REUNIERR   14002

Gauge link reunitarisation failed.

Definition at line 126 of file errorcodes.h.

◆ SIZEPROC

#define SIZEPROC   12004

Communicator size does not match expected size.

Definition at line 91 of file errorcodes.h.

◆ SPHIERR

#define SPHIERR   14004

Up/down partitioning failed.

Definition at line 132 of file errorcodes.h.

◆ STRDERROR

#define STRDERROR   11006

Undefined stride.

Definition at line 68 of file errorcodes.h.

◆ UDPERR

#define UDPERR   14003

Up/down partitioning failed.

Definition at line 130 of file errorcodes.h.

◆ WRITERROR

#define WRITERROR   10003

Error writing to file.

Definition at line 36 of file errorcodes.h.

◆ WRITEWARN

#define WRITEWARN   10103

Minor issue writing to file.

Definition at line 47 of file errorcodes.h.