1 /*
2 Copyright (C) 2008-2021 Michele Martone
3 
4 This file is part of librsb.
5 
6 librsb is free software; you can redistribute it and/or modify it
7 under the terms of the GNU Lesser General Public License as published
8 by the Free Software Foundation; either version 3 of the License, or
9 (at your option) any later version.
10 
11 librsb is distributed in the hope that it will be useful, but WITHOUT
12 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
14 License for more details.
15 
16 You should have received a copy of the GNU Lesser General Public
17 License along with librsb; see the file COPYING.
18 If not, see <http://www.gnu.org/licenses/>.
19 
20 */
21 /* @cond INNERDOC */
22 /*
23  * @author Michele Martone
24  */
25 #ifndef RSB_ERR_H_INCLUDED
26 #define RSB_ERR_H_INCLUDED
27 
28 #ifdef __cplusplus
29 extern "C" {
30 #endif /* __cplusplus */
31 
32 #include "rsb_common.h"
33 
34 #define RSB_ERRM_E_MTXAP	"Supplied NULL  matrix structure pointer !"
35 #define RSB_ERRM_E_MTXAPP	"Supplied NULL  matrix structure pointer pointer !"
36 #define RSB_ERRM_E_VIJ	"Supplied NULL  VA, IA, JA arrays !"
37 #define RSB_ERRM_E_VIJP	"Supplied NULL  VAP, IAP, JAP arrays !"
38 #define RSB_ERRM_CNHEAF	"Cannot reuse arrays while passing them as const."
39 #define RSB_ERRM_EM	"!\n"
40 #define RSB_ERRM_NULL_VA "Supplied VA array pointer!\n"
41 #define RSB_ERRM_BCE	"Internal bounds computing error!\n"
42 #define RSB_ERRM_ZSM	"WARNING : zero sized malloc !\n"
43 #define RSB_ERRM_BFEANS	"Bad flags: RSB_FLAG_EXTERNALLY_ALLOCATED_ARRAYS are not supported here!\n"
44 #define RSB_ERRM_SEOWS	"some error occurred while shuffling\n"
45 #define RSB_ERRM_ALSMINT	"a leaf submatrix is non terminal!\n"
46 #define RSB_ERRM_ANLSMIT	"a non leaf submatrix is terminal!\n"
47 #define RSB_ERRM_FAOTAFS	"failed allocation of temporary array for swap"
48 #define RSB_ERRM_ES	""
49 #define RSB_ERRM_NPSFF	"NULL pointer supplied for filename."
50 #define RSB_ERRM_CBAEM	"Cannot build and empty matrix.\n"
51 #define RSB_ERRM_CMOINIY	"Column Major order is not implemented yet.\n"
52 #define RSB_ERRM_MDNFARTS	"matrix does not fit as RCSR (too sparse)!\n"
53 #define RSB_ERRM_FYRYNS	"fatal : your rsb_coo_idx_t type is not supported.."
54 #define RSB_ERRM_WTC		"error : specified type code is not valid\n"
55 #define RSB_ERRM_COVMUINS	"control of virtual memory usage is not supported\n"
56 #define RSB_ERRM_FCOVMU		"failed control of virtual memory usage\n"
57 #define RSB_ERRM_PFTM		"Problems finalizing the matrix!\n"
58 #define RSB_ERRM_WUF		"WARNING: unfinished code!\n"
59 #define RSB_ERRM_PAL		"probable allocation problem\n"
60 #define RSB_ERRM_NAOL		"no array of leaves ?\n"
61 #define RSB_ERRM_NNTC		"no nonzeros to clone ?\n"
62 #define RSB_ERRM_NDIANN		"no diagonal implicit and no nonzeros ?\n"
63 #define RSB_ERRM_CP		"cleanup problem\n"
64 #define RSB_ERRM_BNCS		"blocking not correctly specified!\n"
65 #define RSB_ERRM_CIIAUF		"Clique insertion is an unfinished functionality!\n"
66 #define RSB_ERRM_FMMTDT		"failed matrix multiplication to dense test\n"
67 #define RSB_ERRM_FMATD		"failed matrix add to dense\n"
68 #define RSB_ERRM_FMM		"failed matrix multiplication\n"
69 #define RSB_ERRM_FMC		"failed matrix cloning\n"
70 #define RSB_ERRM_CMINBC		"cloned matrix is not built correctly\n"
71 #define RSB_ERRM_FCMS		"Failed computing matrix sum.\n"
72 #define RSB_ERRM_FMATDBC	"failed matrix add to dense basic checksum\n"
73 #define RSB_ERRM_FYCITINS	"fatal : your rsb_coo_idx_t type is not supported.."
74 #define RSB_ERRM_WOPSTASA	"WARNING : overflow possible. Switching to another sort algorithm.\n"
75 #define RSB_ERRM_SLIINS		"error : seems like input is not sorted\n"
76 #define RSB_ERRM_EWEFCFD	"error while estimating fillin (corrupt fillin data?)\n"
77 #define RSB_ERRM_EWEFCTD	"error while estimating fillin (corrupt timing data?)\n"
78 #define RSB_ERRM_ERROR		"error\n"
79 #define RSB_ERRM_ESIIB		"error : sorting input is bad\n"
80 #define RSB_ERRM_SLSIB		"error : seems like sorting is bugged\n"
81 #define RSB_ERRM_SIL		"error initializing library!\n"
82 #define RSB_ERRM_SILTC          "Error initializing the library! Nevertheless continuing just to print configuration info (something might be wrong though, and this can help diagnose the problem). Program will return an error code anyway.\n"
83 #define RSB_ERRM_EDNC		"error during nonzeros compacting\n"
84 #define RSB_ERRM_ZCFRWAEC	"zero compacting function returned with an error code\n"
85 #define RSB_ERRM_EQRPF		"error reading performance file.\n"
86 #define RSB_ERRM_ELMPF		"error loading memory performance file.\n"
87 #define RSB_ERRM_AE		"allocation error\n"
88 #define RSB_ERRM_IE		"internal error ?\n"
89 #define RSB_ERRM_NL		"\n"
90 #define RSB_ERRM_MBE		"matrix build error!\n"
91 #define RSB_ERRM_BM		"bad mtxAp:"
92 #define RSB_ERRM_TS		"a problem occurred in triangular solve!\n"
93 #define RSB_ERRM_BOH_TRI	"triangular solve requires either a lower, or an upper triangle!\n"
94 #define RSB_ERRM_MV		"a problem occurred in sparse matrix-vector product!\n"
95 #define RSB_ERRM_NOLP		"timer-based profiling has not been enabled at configure time!\n"
96 #define RSB_ERRM_IMNIP		"input matrix is not an in place one!\n"
97 #define RSB_ERRM_DNSAMIWAFCB		"Did not supply a matrix initiated with rsb_mtx_alloc_from_coo_begin!\n"
98 #define RSB_ERRM_IPEWIEM	"Internal problem encounted when initiating an empty matrix\n"
99 #define RSB_ERRM_NO_XDR	"No XDR configured in: binary matrix I/O disabled.\n"
100 
101 rsb_err_t rsb__do_perror(FILE *stream, rsb_err_t errval);
102 /*const rsb_char_t * rsb__do_strerror_r(rsb_err_t errval, rsb_char_t * buf, size_t buflen);*/
103 rsb_err_t rsb__do_strerror_r(rsb_err_t errval, rsb_char_t * buf, size_t buflen);
104 
105 #ifdef __cplusplus
106 }
107 #endif  /* __cplusplus */
108 
109 #endif /* RSB_ERR_H_INCLUDED */
110 /* @endcond */
111