~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/probes.h

  • Committer: Brian Aker
  • Date: 2008-11-03 03:49:00 UTC
  • mfrom: (520.4.50 devel)
  • Revision ID: brian@tangent.org-20081103034900-znhvcgtipr3tlel5
Merging in Monty's work

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
#ifndef _PROBES_H
6
6
#define _PROBES_H
7
7
 
8
 
 
 
8
#include <unistd.h>
9
9
 
10
10
#ifdef  __cplusplus
11
11
extern "C" {
12
12
#endif
13
13
 
14
 
#if defined(_DTRACE_VERSION)
 
14
#if _DTRACE_VERSION
15
15
 
16
16
#define DRIZZLE_DELETE_END() \
17
 
        __dtrace_mysql___delete_end()
18
 
#define DRIZZLE_DELETE_END_ENABLED() \
19
 
        __dtraceenabled_mysql___delete_end()
 
17
        __dtrace_drizzle___delete_end()
 
18
#ifndef __sparc
 
19
#define DRIZZLE_DELETE_END_ENABLED() \
 
20
        __dtraceenabled_drizzle___delete_end()
 
21
#else
 
22
#define DRIZZLE_DELETE_END_ENABLED() \
 
23
        __dtraceenabled_drizzle___delete_end(0)
 
24
#endif
20
25
#define DRIZZLE_DELETE_START() \
21
 
        __dtrace_mysql___delete_start()
22
 
#define DRIZZLE_DELETE_START_ENABLED() \
23
 
        __dtraceenabled_mysql___delete_start()
 
26
        __dtrace_drizzle___delete_start()
 
27
#ifndef __sparc
 
28
#define DRIZZLE_DELETE_START_ENABLED() \
 
29
        __dtraceenabled_drizzle___delete_start()
 
30
#else
 
31
#define DRIZZLE_DELETE_START_ENABLED() \
 
32
        __dtraceenabled_drizzle___delete_start(0)
 
33
#endif
24
34
#define DRIZZLE_EXTERNAL_LOCK(arg0) \
25
 
        __dtrace_mysql___external_lock(arg0)
26
 
#define DRIZZLE_EXTERNAL_LOCK_ENABLED() \
27
 
        __dtraceenabled_mysql___external_lock()
 
35
        __dtrace_drizzle___external_lock(arg0)
 
36
#ifndef __sparc
 
37
#define DRIZZLE_EXTERNAL_LOCK_ENABLED() \
 
38
        __dtraceenabled_drizzle___external_lock()
 
39
#else
 
40
#define DRIZZLE_EXTERNAL_LOCK_ENABLED() \
 
41
        __dtraceenabled_drizzle___external_lock(0)
 
42
#endif
28
43
#define DRIZZLE_FILESORT_END() \
29
 
        __dtrace_mysql___filesort_end()
30
 
#define DRIZZLE_FILESORT_END_ENABLED() \
31
 
        __dtraceenabled_mysql___filesort_end()
 
44
        __dtrace_drizzle___filesort_end()
 
45
#ifndef __sparc
 
46
#define DRIZZLE_FILESORT_END_ENABLED() \
 
47
        __dtraceenabled_drizzle___filesort_end()
 
48
#else
 
49
#define DRIZZLE_FILESORT_END_ENABLED() \
 
50
        __dtraceenabled_drizzle___filesort_end(0)
 
51
#endif
32
52
#define DRIZZLE_FILESORT_START() \
33
 
        __dtrace_mysql___filesort_start()
34
 
#define DRIZZLE_FILESORT_START_ENABLED() \
35
 
        __dtraceenabled_mysql___filesort_start()
 
53
        __dtrace_drizzle___filesort_start()
 
54
#ifndef __sparc
 
55
#define DRIZZLE_FILESORT_START_ENABLED() \
 
56
        __dtraceenabled_drizzle___filesort_start()
 
57
#else
 
58
#define DRIZZLE_FILESORT_START_ENABLED() \
 
59
        __dtraceenabled_drizzle___filesort_start(0)
 
60
#endif
36
61
#define DRIZZLE_INSERT_END() \
37
 
        __dtrace_mysql___insert_end()
38
 
#define DRIZZLE_INSERT_END_ENABLED() \
39
 
        __dtraceenabled_mysql___insert_end()
 
62
        __dtrace_drizzle___insert_end()
 
63
#ifndef __sparc
 
64
#define DRIZZLE_INSERT_END_ENABLED() \
 
65
        __dtraceenabled_drizzle___insert_end()
 
66
#else
 
67
#define DRIZZLE_INSERT_END_ENABLED() \
 
68
        __dtraceenabled_drizzle___insert_end(0)
 
69
#endif
40
70
#define DRIZZLE_INSERT_ROW_END() \
41
 
        __dtrace_mysql___insert_row_end()
42
 
#define DRIZZLE_INSERT_ROW_END_ENABLED() \
43
 
        __dtraceenabled_mysql___insert_row_end()
 
71
        __dtrace_drizzle___insert_row_end()
 
72
#ifndef __sparc
 
73
#define DRIZZLE_INSERT_ROW_END_ENABLED() \
 
74
        __dtraceenabled_drizzle___insert_row_end()
 
75
#else
 
76
#define DRIZZLE_INSERT_ROW_END_ENABLED() \
 
77
        __dtraceenabled_drizzle___insert_row_end(0)
 
78
#endif
44
79
#define DRIZZLE_INSERT_ROW_START() \
45
 
        __dtrace_mysql___insert_row_start()
46
 
#define DRIZZLE_INSERT_ROW_START_ENABLED() \
47
 
        __dtraceenabled_mysql___insert_row_start()
 
80
        __dtrace_drizzle___insert_row_start()
 
81
#ifndef __sparc
 
82
#define DRIZZLE_INSERT_ROW_START_ENABLED() \
 
83
        __dtraceenabled_drizzle___insert_row_start()
 
84
#else
 
85
#define DRIZZLE_INSERT_ROW_START_ENABLED() \
 
86
        __dtraceenabled_drizzle___insert_row_start(0)
 
87
#endif
48
88
#define DRIZZLE_INSERT_START() \
49
 
        __dtrace_mysql___insert_start()
50
 
#define DRIZZLE_INSERT_START_ENABLED() \
51
 
        __dtraceenabled_mysql___insert_start()
 
89
        __dtrace_drizzle___insert_start()
 
90
#ifndef __sparc
 
91
#define DRIZZLE_INSERT_START_ENABLED() \
 
92
        __dtraceenabled_drizzle___insert_start()
 
93
#else
 
94
#define DRIZZLE_INSERT_START_ENABLED() \
 
95
        __dtraceenabled_drizzle___insert_start(0)
 
96
#endif
52
97
#define DRIZZLE_SELECT_END() \
53
 
        __dtrace_mysql___select_end()
54
 
#define DRIZZLE_SELECT_END_ENABLED() \
55
 
        __dtraceenabled_mysql___select_end()
 
98
        __dtrace_drizzle___select_end()
 
99
#ifndef __sparc
 
100
#define DRIZZLE_SELECT_END_ENABLED() \
 
101
        __dtraceenabled_drizzle___select_end()
 
102
#else
 
103
#define DRIZZLE_SELECT_END_ENABLED() \
 
104
        __dtraceenabled_drizzle___select_end(0)
 
105
#endif
56
106
#define DRIZZLE_SELECT_START() \
57
 
        __dtrace_mysql___select_start()
58
 
#define DRIZZLE_SELECT_START_ENABLED() \
59
 
        __dtraceenabled_mysql___select_start()
 
107
        __dtrace_drizzle___select_start()
 
108
#ifndef __sparc
 
109
#define DRIZZLE_SELECT_START_ENABLED() \
 
110
        __dtraceenabled_drizzle___select_start()
 
111
#else
 
112
#define DRIZZLE_SELECT_START_ENABLED() \
 
113
        __dtraceenabled_drizzle___select_start(0)
 
114
#endif
60
115
#define DRIZZLE_UPDATE_END() \
61
 
        __dtrace_mysql___update_end()
62
 
#define DRIZZLE_UPDATE_END_ENABLED() \
63
 
        __dtraceenabled_mysql___update_end()
 
116
        __dtrace_drizzle___update_end()
 
117
#ifndef __sparc
 
118
#define DRIZZLE_UPDATE_END_ENABLED() \
 
119
        __dtraceenabled_drizzle___update_end()
 
120
#else
 
121
#define DRIZZLE_UPDATE_END_ENABLED() \
 
122
        __dtraceenabled_drizzle___update_end(0)
 
123
#endif
64
124
#define DRIZZLE_UPDATE_START() \
65
 
        __dtrace_mysql___update_start()
66
 
#define DRIZZLE_UPDATE_START_ENABLED() \
67
 
        __dtraceenabled_mysql___update_start()
68
 
 
69
 
 
70
 
extern void __dtrace_mysql___delete_end(void);
71
 
extern int __dtraceenabled_mysql___delete_end(void);
72
 
extern void __dtrace_mysql___delete_start(void);
73
 
extern int __dtraceenabled_mysql___delete_start(void);
74
 
extern void __dtrace_mysql___external_lock(int);
75
 
extern int __dtraceenabled_mysql___external_lock(void);
76
 
extern void __dtrace_mysql___filesort_end(void);
77
 
extern int __dtraceenabled_mysql___filesort_end(void);
78
 
extern void __dtrace_mysql___filesort_start(void);
79
 
extern int __dtraceenabled_mysql___filesort_start(void);
80
 
extern void __dtrace_mysql___insert_end(void);
81
 
extern int __dtraceenabled_mysql___insert_end(void);
82
 
extern void __dtrace_mysql___insert_row_end(void);
83
 
extern int __dtraceenabled_mysql___insert_row_end(void);
84
 
extern void __dtrace_mysql___insert_row_start(void);
85
 
extern int __dtraceenabled_mysql___insert_row_start(void);
86
 
extern void __dtrace_mysql___insert_start(void);
87
 
extern int __dtraceenabled_mysql___insert_start(void);
88
 
extern void __dtrace_mysql___select_end(void);
89
 
extern int __dtraceenabled_mysql___select_end(void);
90
 
extern void __dtrace_mysql___select_start(void);
91
 
extern int __dtraceenabled_mysql___select_start(void);
92
 
extern void __dtrace_mysql___update_end(void);
93
 
extern int __dtraceenabled_mysql___update_end(void);
94
 
extern void __dtrace_mysql___update_start(void);
95
 
extern int __dtraceenabled_mysql___update_start(void);
 
125
        __dtrace_drizzle___update_start()
 
126
#ifndef __sparc
 
127
#define DRIZZLE_UPDATE_START_ENABLED() \
 
128
        __dtraceenabled_drizzle___update_start()
 
129
#else
 
130
#define DRIZZLE_UPDATE_START_ENABLED() \
 
131
        __dtraceenabled_drizzle___update_start(0)
 
132
#endif
 
133
 
 
134
 
 
135
extern void __dtrace_drizzle___delete_end(void);
 
136
#ifndef __sparc
 
137
extern int __dtraceenabled_drizzle___delete_end(void);
 
138
#else
 
139
extern int __dtraceenabled_drizzle___delete_end(long);
 
140
#endif
 
141
extern void __dtrace_drizzle___delete_start(void);
 
142
#ifndef __sparc
 
143
extern int __dtraceenabled_drizzle___delete_start(void);
 
144
#else
 
145
extern int __dtraceenabled_drizzle___delete_start(long);
 
146
#endif
 
147
extern void __dtrace_drizzle___external_lock(int);
 
148
#ifndef __sparc
 
149
extern int __dtraceenabled_drizzle___external_lock(void);
 
150
#else
 
151
extern int __dtraceenabled_drizzle___external_lock(long);
 
152
#endif
 
153
extern void __dtrace_drizzle___filesort_end(void);
 
154
#ifndef __sparc
 
155
extern int __dtraceenabled_drizzle___filesort_end(void);
 
156
#else
 
157
extern int __dtraceenabled_drizzle___filesort_end(long);
 
158
#endif
 
159
extern void __dtrace_drizzle___filesort_start(void);
 
160
#ifndef __sparc
 
161
extern int __dtraceenabled_drizzle___filesort_start(void);
 
162
#else
 
163
extern int __dtraceenabled_drizzle___filesort_start(long);
 
164
#endif
 
165
extern void __dtrace_drizzle___insert_end(void);
 
166
#ifndef __sparc
 
167
extern int __dtraceenabled_drizzle___insert_end(void);
 
168
#else
 
169
extern int __dtraceenabled_drizzle___insert_end(long);
 
170
#endif
 
171
extern void __dtrace_drizzle___insert_row_end(void);
 
172
#ifndef __sparc
 
173
extern int __dtraceenabled_drizzle___insert_row_end(void);
 
174
#else
 
175
extern int __dtraceenabled_drizzle___insert_row_end(long);
 
176
#endif
 
177
extern void __dtrace_drizzle___insert_row_start(void);
 
178
#ifndef __sparc
 
179
extern int __dtraceenabled_drizzle___insert_row_start(void);
 
180
#else
 
181
extern int __dtraceenabled_drizzle___insert_row_start(long);
 
182
#endif
 
183
extern void __dtrace_drizzle___insert_start(void);
 
184
#ifndef __sparc
 
185
extern int __dtraceenabled_drizzle___insert_start(void);
 
186
#else
 
187
extern int __dtraceenabled_drizzle___insert_start(long);
 
188
#endif
 
189
extern void __dtrace_drizzle___select_end(void);
 
190
#ifndef __sparc
 
191
extern int __dtraceenabled_drizzle___select_end(void);
 
192
#else
 
193
extern int __dtraceenabled_drizzle___select_end(long);
 
194
#endif
 
195
extern void __dtrace_drizzle___select_start(void);
 
196
#ifndef __sparc
 
197
extern int __dtraceenabled_drizzle___select_start(void);
 
198
#else
 
199
extern int __dtraceenabled_drizzle___select_start(long);
 
200
#endif
 
201
extern void __dtrace_drizzle___update_end(void);
 
202
#ifndef __sparc
 
203
extern int __dtraceenabled_drizzle___update_end(void);
 
204
#else
 
205
extern int __dtraceenabled_drizzle___update_end(long);
 
206
#endif
 
207
extern void __dtrace_drizzle___update_start(void);
 
208
#ifndef __sparc
 
209
extern int __dtraceenabled_drizzle___update_start(void);
 
210
#else
 
211
extern int __dtraceenabled_drizzle___update_start(long);
 
212
#endif
96
213
 
97
214
#else
98
215