This header is intended to be a useful reference for error codes and their meanings. More...
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. | |
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.
| #define ARGERROR 10004 |
Error with argument.
Definition at line 38 of file errorcodes.h.
| #define ARGWARN 10104 |
Minor argument issue.
Definition at line 49 of file errorcodes.h.
| #define ARRAYLEN 11004 |
Impossible value for array length.
Definition at line 64 of file errorcodes.h.
| #define BLOCKALERT 15201 |
Alert with block size.
Definition at line 161 of file errorcodes.h.
| #define BLOCKERROR 15001 |
Error with setting block size.
Definition at line 151 of file errorcodes.h.
| #define BLOCKWARN 15101 |
Warning with block size.
Definition at line 156 of file errorcodes.h.
| #define BOUNDERROR 11003 |
Accessing out of bounds element.
Definition at line 62 of file errorcodes.h.
| #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.
| #define BROADERR 12008 |
Couldn't broadcast to the processes.
Definition at line 99 of file errorcodes.h.
| #define CANTRECV 12007 |
Couldn't receive from another process.
Definition at line 97 of file errorcodes.h.
| #define CANTSEND 12006 |
Couldn't send to another process.
Definition at line 95 of file errorcodes.h.
| #define CONVERR 14003 |
Failed to convert precision correctly.
Definition at line 128 of file errorcodes.h.
| #define COORDTOIND 11002 |
Issues converting coordinate to index.
Definition at line 60 of file errorcodes.h.
| #define CPYERROR 11005 |
Copy failed.
Definition at line 66 of file errorcodes.h.
| #define CPYWARN 11105 |
Copy failed.
Definition at line 77 of file errorcodes.h.
| #define DIFNPROC 12101 |
Continuation run on different grid size.
Definition at line 108 of file errorcodes.h.
| #define DIVZERO 14001 |
Division by zero.
Definition at line 124 of file errorcodes.h.
| #define FITWARN 14102 |
Fitting function has repeated x value.
Definition at line 139 of file errorcodes.h.
| #define GATHERR 12010 |
Couldn't complete a gather operation.
Definition at line 103 of file errorcodes.h.
| #define HALOLIM 13002 |
Index goes beyond the halo.
Definition at line 117 of file errorcodes.h.
| #define INDTOCOORD 11001 |
Issues converting index to coordinates.
Leading digits are 11
Definition at line 58 of file errorcodes.h.
| #define ITERLIM 14101 |
Exceeded max number of iterations.
Definition at line 137 of file errorcodes.h.
| #define LAYERROR 13001 |
brief Can't access a layer of a halo
Definition at line 115 of file errorcodes.h.
| #define LIMWARN 11104 |
Order of limits (x_min and x_max for example) is reversed.
Definition at line 75 of file errorcodes.h.
| #define NO_MPI_INIT 12001 |
Failed to initialise MPI.
Definition at line 85 of file errorcodes.h.
| #define NO_MPI_RANK 12002 |
Failed to get the rank of the process.
Definition at line 87 of file errorcodes.h.
| #define NO_MPI_SIZE 12003 |
Failed to get the number of ranks.
Definition at line 89 of file errorcodes.h.
| #define NOIMPL 16001 |
| #define NOINIT 14201 |
Not initialising the lattice.
Definition at line 144 of file errorcodes.h.
| #define NUMELEM 12005 |
Failed to evaluate the number of elements.
Definition at line 93 of file errorcodes.h.
| #define OPENERROR 10001 |
Error opening file.
Definition at line 32 of file errorcodes.h.
| #define OPENWARN 10101 |
Minor issue opening file.
Definition at line 43 of file errorcodes.h.
| #define READERROR 10002 |
Error reading file.
Definition at line 34 of file errorcodes.h.
| #define READWARN 10102 |
Minor issue reading file.
Definition at line 45 of file errorcodes.h.
| #define REDUCERR 12009 |
Couldn't carry out a reduction operation.
Definition at line 101 of file errorcodes.h.
| #define REUNIERR 14002 |
Gauge link reunitarisation failed.
Definition at line 126 of file errorcodes.h.
| #define SIZEPROC 12004 |
Communicator size does not match expected size.
Definition at line 91 of file errorcodes.h.
| #define SPHIERR 14004 |
Up/down partitioning failed.
Definition at line 132 of file errorcodes.h.
| #define STRDERROR 11006 |
Undefined stride.
Definition at line 68 of file errorcodes.h.
| #define UDPERR 14003 |
Up/down partitioning failed.
Definition at line 130 of file errorcodes.h.
| #define WRITERROR 10003 |
Error writing to file.
Definition at line 36 of file errorcodes.h.
| #define WRITEWARN 10103 |
Minor issue writing to file.
Definition at line 47 of file errorcodes.h.