DSDP
include
dsdpsys.h
Go to the documentation of this file.
1
#if !defined(__DSDP_KERNAL_H)
2
#define __DSDP_KERNAL_H
3
8
#include <stdio.h>
9
#include <stdlib.h>
10
#include <math.h>
11
#include <string.h>
12
#include <float.h>
13
14
/* Define some macros for error checking */
15
#ifdef __FUNCT__
16
#undef __FUNCT__
17
#endif
18
#define __FUNCT__ "DSDPUnknownFunction"
19
20
/*
21
#ifdef __cplusplus
22
#define DSDPBEGINCROUTINES extern "C" {
23
#define DSDPENDCROUTINES }
24
#else
25
#define DSDPBEGINCROUTINES {
26
#define DSDPENDCROUTINES }
27
#endif
28
*/
29
30
#ifdef __cplusplus
31
extern
"C"
{
32
#endif
33
34
extern
void
DSDPTime(
double
*);
35
36
37
extern
int
DSDPLogInfoAllow(
int
,
char
*);
38
39
extern
void
DSDPError(
const
char
*,
int
,
const
char
*);
40
extern
void
DSDPLogFInfo(
void
*vobj,
int
outlevel,
const
char
message[], ...);
41
extern
int
DSDPFError(
void
*vobj,
const
char
*func,
int
linen,
const
char
*filef,
const
char
message[], ...);
42
43
extern
void
DSDPMemoryLog(
void
);
44
extern
int
DSDPEventLogBegin(
int
);
45
extern
int
DSDPEventLogEnd(
int
);
46
extern
int
DSDPEventLogRegister(
const
char
*,
int
*);
47
extern
int
DSDPEventLogInitialize(
void
);
48
extern
int
DSDPEventLogSummary(
void
);
49
extern
int
DSDPEventLogInitialize(
void
);
50
51
#ifdef __cplusplus
52
}
53
#endif
54
55
56
#ifndef DSDPCHKERR
57
#define DSDPCHKERR(a) { if (a){ DSDPError(__FUNCT__,__LINE__,__FILE__); return a; } }
58
#endif
59
60
#ifdef DSDPFunctionReturn
61
#undef DSDPFunctionReturn
62
#endif
63
#define DSDPFunctionReturn return
64
65
#ifdef DSDPFunctionBegin
66
#undef DSDPFunctionBegin
67
#endif
68
#define DSDPFunctionBegin { }
69
70
#ifdef DSDPMATLAB
71
#include "mex.h"
72
#define DSDPPrintf mexPrintf
73
#define DSDPErrorPrintf mexPrintf
74
#endif
75
76
#include "
dsdpmem.h
"
77
78
#ifndef DSDPPrintf
79
#define DSDPPrintf printf
80
#endif
81
82
#ifndef DSDPErrorPrintf
83
#define DSDPErrorPrintf printf
84
#endif
85
86
#define DSDPLogInfo DSDPLogFInfo
87
/*#define DSDPLogInfo if(0)DSDPLogFInfo */
88
89
90
91
#define DSDPSETERR(a,b) {DSDPFError(0,__FUNCT__,__LINE__,__FILE__,b); return (a); }
92
#define DSDPSETERR1(a,b,c) {DSDPFError(0,__FUNCT__,__LINE__,__FILE__,b,c); return (a); }
93
#define DSDPSETERR2(a,b,c,d) {DSDPFError(0,__FUNCT__,__LINE__,__FILE__,b,c,d); return (a); }
94
#define DSDPSETERR3(a,b,c,d,e) {DSDPFError(0,__FUNCT__,__LINE__,__FILE__,b,c,d,e); return (a); }
95
96
97
/*
98
*/
99
#define DSDPMin(a,b) ((a <= b)? (a) : (b))
100
#define DSDPMax(a,b) ((a >= b)? (a) : (b))
101
102
103
#endif
dsdpmem.h
Memory allocation in DSDP.
Generated by
1.8.17