1 | /* $Id: odinwrap.h,v 1.25 2000-10-02 16:20:11 phaller Exp $ */
|
---|
2 |
|
---|
3 | /*
|
---|
4 | * Project Odin Software License can be found in LICENSE.TXT
|
---|
5 | *
|
---|
6 | * ODIN FS: Selector function wrapper macros
|
---|
7 | *
|
---|
8 | * Copyright 1999 Patrick Haller
|
---|
9 | *
|
---|
10 | */
|
---|
11 |
|
---|
12 |
|
---|
13 | #ifndef _ODINWRAP_H_
|
---|
14 | #define _ODINWRAP_H_
|
---|
15 |
|
---|
16 | #include <os2sel.h>
|
---|
17 |
|
---|
18 | /****************************************************************************
|
---|
19 | * Defines *
|
---|
20 | ****************************************************************************/
|
---|
21 |
|
---|
22 | // override debugging
|
---|
23 | //#undef DEBUG
|
---|
24 | //#define DEBUG
|
---|
25 |
|
---|
26 | // override profiling
|
---|
27 | //#undef PROFILE_ODIN
|
---|
28 | //#define PROFILE_ODIN
|
---|
29 |
|
---|
30 |
|
---|
31 |
|
---|
32 | #define ODIN_INTERNAL _Optlink
|
---|
33 |
|
---|
34 |
|
---|
35 | #ifdef DEBUG
|
---|
36 | # define ODINDEBUGCHANNEL(a) static char* pszOdinDebugChannel=#a;
|
---|
37 | # define ODINDEBUGCHANNEL1(a) static char* pszOdinDebugChannel1=#a;
|
---|
38 | #else
|
---|
39 | # define ODINDEBUGCHANNEL(a)
|
---|
40 | # define ODINDEBUGCHANNEL1(a)
|
---|
41 | #endif
|
---|
42 |
|
---|
43 |
|
---|
44 | //SvL: Define this to use the internal wrapper function of a specific api
|
---|
45 | #define ODIN_EXTERN(a) ODIN_INTERNAL ODIN_##a
|
---|
46 |
|
---|
47 |
|
---|
48 |
|
---|
49 |
|
---|
50 | #ifdef DEBUG
|
---|
51 |
|
---|
52 | //@@@PH 1999/10/25 IBM VAC++ debug memory support
|
---|
53 | #include <malloc.h>
|
---|
54 |
|
---|
55 |
|
---|
56 | // ---------------------------------------------------------------------------
|
---|
57 | extern int IsExeStarted(); //kernel32
|
---|
58 |
|
---|
59 |
|
---|
60 | // ---------------------------------------------------------------------------
|
---|
61 | //SvL: Only check the heap very frequently when there are problems
|
---|
62 | //#define DEBUG_ODINHEAP
|
---|
63 | #ifdef DEBUG_ODINHEAP
|
---|
64 | #define ODIN_HEAPCHECK() _heap_check()
|
---|
65 | #else
|
---|
66 | #define ODIN_HEAPCHECK()
|
---|
67 | #endif
|
---|
68 |
|
---|
69 |
|
---|
70 | // ---------------------------------------------------------------------------
|
---|
71 | // PH: this is for profiling cumulative method call times
|
---|
72 | #ifdef PROFILE_ODIN
|
---|
73 |
|
---|
74 | # define PROFILE_START(a) \
|
---|
75 | LARGE_INTEGER liStart; \
|
---|
76 | LARGE_INTEGER liEnd; \
|
---|
77 | unsigned long ulElapsed; \
|
---|
78 | QueryPerformanceCounter(&liStart);
|
---|
79 |
|
---|
80 |
|
---|
81 | # define PROFILE_STOP(a) \
|
---|
82 | QueryPerformanceCounter(&liEnd);\
|
---|
83 | if (liStart.LowPart > liEnd.LowPart) \
|
---|
84 | ulElapsed = 0xFFFFFFFF - liStart.LowPart + liEnd.LowPart; \
|
---|
85 | else \
|
---|
86 | ulElapsed = liEnd.LowPart - liStart.LowPart; \
|
---|
87 | \
|
---|
88 | dprintf(("%s: %s %u ticks\n",\
|
---|
89 | pszOdinDebugChannel,\
|
---|
90 | a, \
|
---|
91 | ulElapsed));
|
---|
92 | #else
|
---|
93 | # define PROFILE_START(a)
|
---|
94 | # define PROFILE_STOP(a)
|
---|
95 | #endif
|
---|
96 |
|
---|
97 |
|
---|
98 | #define FNPROLOGUE(a) \
|
---|
99 | USHORT sel = GetFS(); \
|
---|
100 | ODIN_HEAPCHECK(); \
|
---|
101 | PROFILE_START(a)
|
---|
102 |
|
---|
103 | #define FNEPILOGUE(a) \
|
---|
104 | PROFILE_STOP(a) \
|
---|
105 | ODIN_HEAPCHECK(); \
|
---|
106 | if (sel != GetFS() && IsExeStarted()) \
|
---|
107 | dprintf(("ERROR: FS: for thread %08xh corrupted!", GetCurrentThreadId()));
|
---|
108 |
|
---|
109 |
|
---|
110 | /****************************************************************************
|
---|
111 | * General Wrapper Macros (debug instrumented) *
|
---|
112 | ****************************************************************************/
|
---|
113 |
|
---|
114 | /* ---------- 0 parameters ---------- */
|
---|
115 | #define ODINFUNCTION0(cRet,cName) \
|
---|
116 | cRet ODIN_INTERNAL ODIN_##cName (void); \
|
---|
117 | cRet WINAPI cName(void) \
|
---|
118 | { \
|
---|
119 | dprintfNoEOL(("%s: "#cRet" "#cName"()", \
|
---|
120 | pszOdinDebugChannel)); \
|
---|
121 | FNPROLOGUE(#cName) \
|
---|
122 | cRet rc = ODIN_##cName(); \
|
---|
123 | FNEPILOGUE(#cName) \
|
---|
124 | dprintf(("- rc = %08xh\n", rc)); \
|
---|
125 | return rc; \
|
---|
126 | } \
|
---|
127 | \
|
---|
128 | cRet ODIN_INTERNAL ODIN_##cName (void)
|
---|
129 |
|
---|
130 |
|
---|
131 | #define ODINPROCEDURE0(cName) \
|
---|
132 | void ODIN_INTERNAL ODIN_##cName (void); \
|
---|
133 | void WINAPI cName(void) \
|
---|
134 | { \
|
---|
135 | dprintfNoEOL(("%s: void "#cName"()", \
|
---|
136 | pszOdinDebugChannel)); \
|
---|
137 | FNPROLOGUE(#cName) \
|
---|
138 | ODIN_##cName(); \
|
---|
139 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
140 | pszOdinDebugChannel)); \
|
---|
141 | FNEPILOGUE(#cName) \
|
---|
142 | } \
|
---|
143 | \
|
---|
144 | void ODIN_INTERNAL ODIN_##cName (void)
|
---|
145 |
|
---|
146 |
|
---|
147 | /* ---------- 1 parameters ---------- */
|
---|
148 | #define ODINFUNCTION1(cRet,cName,t1,a1) \
|
---|
149 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1); \
|
---|
150 | cRet WINAPI cName(t1 a1) \
|
---|
151 | { \
|
---|
152 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh)", \
|
---|
153 | pszOdinDebugChannel, \
|
---|
154 | a1)); \
|
---|
155 | FNPROLOGUE(#cName) \
|
---|
156 | cRet rc = ODIN_##cName(a1); \
|
---|
157 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
158 | pszOdinDebugChannel, \
|
---|
159 | rc)); \
|
---|
160 | FNEPILOGUE(#cName) \
|
---|
161 | return rc; \
|
---|
162 | } \
|
---|
163 | \
|
---|
164 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1)
|
---|
165 |
|
---|
166 | #define ODINPROCEDURE1(cName,t1,a1) \
|
---|
167 | void ODIN_INTERNAL ODIN_##cName (t1 a1); \
|
---|
168 | void WINAPI cName(t1 a1) \
|
---|
169 | { \
|
---|
170 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh)", \
|
---|
171 | pszOdinDebugChannel, \
|
---|
172 | a1)); \
|
---|
173 | FNPROLOGUE(#cName) \
|
---|
174 | ODIN_##cName(a1); \
|
---|
175 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
176 | pszOdinDebugChannel)); \
|
---|
177 | FNEPILOGUE(#cName) \
|
---|
178 | } \
|
---|
179 | \
|
---|
180 | void ODIN_INTERNAL ODIN_##cName (t1 a1)
|
---|
181 |
|
---|
182 |
|
---|
183 | /* ---------- 2 parameters ---------- */
|
---|
184 | #define ODINFUNCTION2(cRet,cName,t1,a1,t2,a2) \
|
---|
185 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2); \
|
---|
186 | cRet WINAPI cName(t1 a1,t2 a2) \
|
---|
187 | { \
|
---|
188 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh)", \
|
---|
189 | pszOdinDebugChannel, \
|
---|
190 | a1,a2)); \
|
---|
191 | FNPROLOGUE(#cName) \
|
---|
192 | cRet rc = ODIN_##cName(a1,a2); \
|
---|
193 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
194 | pszOdinDebugChannel, \
|
---|
195 | rc)); \
|
---|
196 | FNEPILOGUE(#cName) \
|
---|
197 | return rc; \
|
---|
198 | } \
|
---|
199 | \
|
---|
200 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2)
|
---|
201 |
|
---|
202 | #define ODINPROCEDURE2(cName,t1,a1,t2,a2) \
|
---|
203 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2); \
|
---|
204 | void WINAPI cName(t1 a1,t2 a2) \
|
---|
205 | { \
|
---|
206 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh)", \
|
---|
207 | pszOdinDebugChannel, \
|
---|
208 | a1,a2)); \
|
---|
209 | FNPROLOGUE(#cName) \
|
---|
210 | ODIN_##cName(a1,a2); \
|
---|
211 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
212 | pszOdinDebugChannel)); \
|
---|
213 | FNEPILOGUE(#cName) \
|
---|
214 | } \
|
---|
215 | \
|
---|
216 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2)
|
---|
217 |
|
---|
218 |
|
---|
219 | /* ---------- 3 parameters ---------- */
|
---|
220 | #define ODINFUNCTION3(cRet,cName,t1,a1,t2,a2,t3,a3) \
|
---|
221 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3); \
|
---|
222 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3) \
|
---|
223 | { \
|
---|
224 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)", \
|
---|
225 | pszOdinDebugChannel, \
|
---|
226 | a1,a2,a3)); \
|
---|
227 | FNPROLOGUE(#cName) \
|
---|
228 | cRet rc = ODIN_##cName(a1,a2,a3); \
|
---|
229 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
230 | pszOdinDebugChannel, \
|
---|
231 | rc)); \
|
---|
232 | FNEPILOGUE(#cName) \
|
---|
233 | return rc; \
|
---|
234 | } \
|
---|
235 | \
|
---|
236 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3)
|
---|
237 |
|
---|
238 | #define ODINPROCEDURE3(cName,t1,a1,t2,a2,t3,a3) \
|
---|
239 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3); \
|
---|
240 | void WINAPI cName(t1 a1,t2 a2,t3 a3) \
|
---|
241 | { \
|
---|
242 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)", \
|
---|
243 | pszOdinDebugChannel, \
|
---|
244 | a1,a2,a3)); \
|
---|
245 | FNPROLOGUE(#cName) \
|
---|
246 | ODIN_##cName(a1,a2,a3); \
|
---|
247 | pszOdinDebugChannel)); \
|
---|
248 | FNEPILOGUE(#cName) \
|
---|
249 | } \
|
---|
250 | \
|
---|
251 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3)
|
---|
252 |
|
---|
253 |
|
---|
254 | /* ---------- 4 parameters ---------- */
|
---|
255 | #define ODINFUNCTION4(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4) \
|
---|
256 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4); \
|
---|
257 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4) \
|
---|
258 | { \
|
---|
259 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh, "#t4" "#a4"=%08xh)", \
|
---|
260 | pszOdinDebugChannel, \
|
---|
261 | a1,a2,a3,a4)); \
|
---|
262 | FNPROLOGUE(#cName) \
|
---|
263 | cRet rc = ODIN_##cName(a1,a2,a3,a4); \
|
---|
264 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
265 | pszOdinDebugChannel, \
|
---|
266 | rc)); \
|
---|
267 | FNEPILOGUE(#cName) \
|
---|
268 | return rc; \
|
---|
269 | } \
|
---|
270 | \
|
---|
271 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4)
|
---|
272 |
|
---|
273 | #define ODINPROCEDURE4(cName,t1,a1,t2,a2,t3,a3,t4,a4) \
|
---|
274 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4); \
|
---|
275 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4) \
|
---|
276 | { \
|
---|
277 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh, "#t4" "#a4"=%08xh)", \
|
---|
278 | pszOdinDebugChannel, \
|
---|
279 | a1,a2,a3,a4)); \
|
---|
280 | FNPROLOGUE(#cName) \
|
---|
281 | ODIN_##cName(a1,a2,a3,a4); \
|
---|
282 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
283 | pszOdinDebugChannel)); \
|
---|
284 | FNEPILOGUE \
|
---|
285 | } \
|
---|
286 | \
|
---|
287 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4)
|
---|
288 |
|
---|
289 |
|
---|
290 | /* ---------- 5 parameters ---------- */
|
---|
291 | #define ODINFUNCTION5(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5) \
|
---|
292 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5); \
|
---|
293 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5) \
|
---|
294 | { \
|
---|
295 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh" \
|
---|
296 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh)", \
|
---|
297 | pszOdinDebugChannel, \
|
---|
298 | a1,a2,a3,a4,a5)); \
|
---|
299 | FNPROLOGUE(#cName) \
|
---|
300 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5); \
|
---|
301 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
302 | pszOdinDebugChannel, \
|
---|
303 | rc)); \
|
---|
304 | FNEPILOGUE(#cName) \
|
---|
305 | return rc; \
|
---|
306 | } \
|
---|
307 | \
|
---|
308 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5)
|
---|
309 |
|
---|
310 | #define ODINPROCEDURE5(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5) \
|
---|
311 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5); \
|
---|
312 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5) \
|
---|
313 | { \
|
---|
314 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
315 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh)", \
|
---|
316 | pszOdinDebugChannel, \
|
---|
317 | a1,a2,a3,a4,a5)); \
|
---|
318 | FNPROLOGUE(#cName) \
|
---|
319 | ODIN_##cName(a1,a2,a3,a4,a5); \
|
---|
320 | pszOdinDebugChannel)); \
|
---|
321 | FNEPILOGUE \
|
---|
322 | } \
|
---|
323 | \
|
---|
324 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5)
|
---|
325 |
|
---|
326 |
|
---|
327 | /* ---------- 6 parameters ---------- */
|
---|
328 | #define ODINFUNCTION6(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6) \
|
---|
329 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6); \
|
---|
330 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6) \
|
---|
331 | { \
|
---|
332 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
333 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh)", \
|
---|
334 | pszOdinDebugChannel, \
|
---|
335 | a1,a2,a3,a4,a5,a6)); \
|
---|
336 | FNPROLOGUE(#cName) \
|
---|
337 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6); \
|
---|
338 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
339 | pszOdinDebugChannel, \
|
---|
340 | rc)); \
|
---|
341 | FNEPILOGUE(#cName) \
|
---|
342 | return rc; \
|
---|
343 | } \
|
---|
344 | \
|
---|
345 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6)
|
---|
346 |
|
---|
347 | // @@@PH 1999/12/28 the following macro is a workaround for WINMM:waveOutOpen
|
---|
348 | // where the system needs to know about the win32 tib fs selector
|
---|
349 | #define ODINFUNCTION6FS(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6) \
|
---|
350 | cRet ODIN_INTERNAL ODIN_##cName (unsigned short selFS, t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6); \
|
---|
351 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6) \
|
---|
352 | { \
|
---|
353 | dprintfNoEOL(("%s: "#cRet" "#cName"(selFS=%04xh, "#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
354 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh)", \
|
---|
355 | pszOdinDebugChannel, \
|
---|
356 | sel, \
|
---|
357 | a1,a2,a3,a4,a5,a6)); \
|
---|
358 | FNPROLOGUE(#cName) \
|
---|
359 | cRet rc = ODIN_##cName(sel,a1,a2,a3,a4,a5,a6); \
|
---|
360 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
361 | pszOdinDebugChannel, \
|
---|
362 | rc)); \
|
---|
363 | FNEPILOGUE(#cName) \
|
---|
364 | return rc; \
|
---|
365 | } \
|
---|
366 | \
|
---|
367 | cRet ODIN_INTERNAL ODIN_##cName (unsigned short selFS, t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6)
|
---|
368 |
|
---|
369 |
|
---|
370 | #define ODINPROCEDURE6(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6) \
|
---|
371 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6); \
|
---|
372 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6) \
|
---|
373 | { \
|
---|
374 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
375 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh)", \
|
---|
376 | pszOdinDebugChannel, \
|
---|
377 | a1,a2,a3,a4,a5,a6)); \
|
---|
378 | FNPROLOGUE(#cName) \
|
---|
379 | ODIN_##cName(a1,a2,a3,a4,a5,a6); \
|
---|
380 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
381 | pszOdinDebugChannel)); \
|
---|
382 | FNEPILOGUE \
|
---|
383 | } \
|
---|
384 | \
|
---|
385 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6)
|
---|
386 |
|
---|
387 |
|
---|
388 | /* ---------- 7 parameters ---------- */
|
---|
389 | #define ODINFUNCTION7(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7) \
|
---|
390 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7); \
|
---|
391 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7) \
|
---|
392 | { \
|
---|
393 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
394 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh)", \
|
---|
395 | pszOdinDebugChannel, \
|
---|
396 | a1,a2,a3,a4,a5,a6,a7)); \
|
---|
397 | FNPROLOGUE(#cName) \
|
---|
398 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7); \
|
---|
399 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
400 | pszOdinDebugChannel, \
|
---|
401 | rc)); \
|
---|
402 | FNEPILOGUE(#cName) \
|
---|
403 | return rc; \
|
---|
404 | } \
|
---|
405 | \
|
---|
406 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7)
|
---|
407 |
|
---|
408 | #define ODINPROCEDURE7(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7) \
|
---|
409 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7); \
|
---|
410 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7) \
|
---|
411 | { \
|
---|
412 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
413 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh)", \
|
---|
414 | pszOdinDebugChannel, \
|
---|
415 | a1,a2,a3,a4,a5,a6,a7)); \
|
---|
416 | FNPROLOGUE(#cName) \
|
---|
417 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7); \
|
---|
418 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
419 | pszOdinDebugChannel)); \
|
---|
420 | FNEPILOGUE \
|
---|
421 | } \
|
---|
422 | \
|
---|
423 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7)
|
---|
424 |
|
---|
425 |
|
---|
426 | /* ---------- 8 parameters ---------- */
|
---|
427 | #define ODINFUNCTION8(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8) \
|
---|
428 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8); \
|
---|
429 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8) \
|
---|
430 | { \
|
---|
431 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
432 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
433 | ", "#t8" "#a8"=%08xh)", \
|
---|
434 | pszOdinDebugChannel, \
|
---|
435 | a1,a2,a3,a4,a5,a6,a7,a8)); \
|
---|
436 | FNPROLOGUE(#cName) \
|
---|
437 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8); \
|
---|
438 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
439 | pszOdinDebugChannel, \
|
---|
440 | rc)); \
|
---|
441 | FNEPILOGUE(#cName) \
|
---|
442 | return rc; \
|
---|
443 | } \
|
---|
444 | \
|
---|
445 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8)
|
---|
446 |
|
---|
447 | #define ODINPROCEDURE8(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8) \
|
---|
448 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8); \
|
---|
449 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8) \
|
---|
450 | { \
|
---|
451 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
452 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
453 | ", "#t8" "#a8"=%08xh)", \
|
---|
454 | pszOdinDebugChannel, \
|
---|
455 | a1,a2,a3,a4,a5,a6,a7,a8)); \
|
---|
456 | FNPROLOGUE(#cName) \
|
---|
457 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8); \
|
---|
458 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
459 | pszOdinDebugChannel)); \
|
---|
460 | FNEPILOGUE \
|
---|
461 | } \
|
---|
462 | \
|
---|
463 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8)
|
---|
464 |
|
---|
465 |
|
---|
466 | /* ---------- 9 parameters ---------- */
|
---|
467 | #define ODINFUNCTION9(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9) \
|
---|
468 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9); \
|
---|
469 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9) \
|
---|
470 | { \
|
---|
471 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
472 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
473 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh)", \
|
---|
474 | pszOdinDebugChannel, \
|
---|
475 | a1,a2,a3,a4,a5,a6,a7,a8,a9)); \
|
---|
476 | FNPROLOGUE(#cName) \
|
---|
477 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9); \
|
---|
478 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
479 | pszOdinDebugChannel, \
|
---|
480 | rc)); \
|
---|
481 | FNEPILOGUE(#cName) \
|
---|
482 | return rc; \
|
---|
483 | } \
|
---|
484 | \
|
---|
485 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9)
|
---|
486 |
|
---|
487 | #define ODINPROCEDURE9(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9) \
|
---|
488 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9); \
|
---|
489 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9) \
|
---|
490 | { \
|
---|
491 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
492 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
493 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh)", \
|
---|
494 | pszOdinDebugChannel, \
|
---|
495 | a1,a2,a3,a4,a5,a6,a7,a8,a9)); \
|
---|
496 | FNPROLOGUE(#cName) \
|
---|
497 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9); \
|
---|
498 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
499 | pszOdinDebugChannel)); \
|
---|
500 | FNEPILOGUE \
|
---|
501 | } \
|
---|
502 | \
|
---|
503 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9)
|
---|
504 |
|
---|
505 |
|
---|
506 | /* ---------- 10 parameters ---------- */
|
---|
507 | #define ODINFUNCTION10(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10) \
|
---|
508 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10); \
|
---|
509 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10) \
|
---|
510 | { \
|
---|
511 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
512 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
513 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh)", \
|
---|
514 | pszOdinDebugChannel, \
|
---|
515 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10));\
|
---|
516 | FNPROLOGUE(#cName) \
|
---|
517 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10); \
|
---|
518 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
519 | pszOdinDebugChannel, \
|
---|
520 | rc)); \
|
---|
521 | FNEPILOGUE(#cName) \
|
---|
522 | return rc; \
|
---|
523 | } \
|
---|
524 | \
|
---|
525 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10)
|
---|
526 |
|
---|
527 | #define ODINPROCEDURE10(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10) \
|
---|
528 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10); \
|
---|
529 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10) \
|
---|
530 | { \
|
---|
531 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
532 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
533 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh)", \
|
---|
534 | pszOdinDebugChannel, \
|
---|
535 | a1,a2,a3)); \
|
---|
536 | FNPROLOGUE(#cName) \
|
---|
537 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10); \
|
---|
538 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
539 | pszOdinDebugChannel)); \
|
---|
540 | FNEPILOGUE \
|
---|
541 | } \
|
---|
542 | \
|
---|
543 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10)
|
---|
544 |
|
---|
545 |
|
---|
546 | /* ---------- 11 parameters ---------- */
|
---|
547 | #define ODINFUNCTION11(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11) \
|
---|
548 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11); \
|
---|
549 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11) \
|
---|
550 | { \
|
---|
551 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
552 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
553 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh)", \
|
---|
554 | pszOdinDebugChannel, \
|
---|
555 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11)); \
|
---|
556 | FNPROLOGUE(#cName) \
|
---|
557 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11); \
|
---|
558 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
559 | pszOdinDebugChannel, \
|
---|
560 | rc)); \
|
---|
561 | FNEPILOGUE(#cName) \
|
---|
562 | return rc; \
|
---|
563 | } \
|
---|
564 | \
|
---|
565 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11)
|
---|
566 |
|
---|
567 | #define ODINPROCEDURE11(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11) \
|
---|
568 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11); \
|
---|
569 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11) \
|
---|
570 | { \
|
---|
571 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
572 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
573 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh)", \
|
---|
574 | pszOdinDebugChannel, \
|
---|
575 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11)); \
|
---|
576 | FNPROLOGUE(#cName) \
|
---|
577 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11); \
|
---|
578 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
579 | pszOdinDebugChannel)); \
|
---|
580 | FNEPILOGUE \
|
---|
581 | } \
|
---|
582 | \
|
---|
583 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11)
|
---|
584 |
|
---|
585 |
|
---|
586 | /* ---------- 12 parameters ---------- */
|
---|
587 | #define ODINFUNCTION12(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12) \
|
---|
588 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12); \
|
---|
589 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12) \
|
---|
590 | { \
|
---|
591 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
592 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
593 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh" \
|
---|
594 | ", "#t12" "#a12"=%08xh)", \
|
---|
595 | pszOdinDebugChannel, \
|
---|
596 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12)); \
|
---|
597 | FNPROLOGUE(#cName) \
|
---|
598 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12); \
|
---|
599 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
600 | pszOdinDebugChannel, \
|
---|
601 | rc)); \
|
---|
602 | FNEPILOGUE(#cName) \
|
---|
603 | return rc; \
|
---|
604 | } \
|
---|
605 | \
|
---|
606 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12)
|
---|
607 |
|
---|
608 | #define ODINPROCEDURE12(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12) \
|
---|
609 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12); \
|
---|
610 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12) \
|
---|
611 | { \
|
---|
612 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
613 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
614 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh" \
|
---|
615 | ", "#t12" "#a12"=%08xh)", \
|
---|
616 | pszOdinDebugChannel, \
|
---|
617 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12)); \
|
---|
618 | FNPROLOGUE(#cName) \
|
---|
619 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12); \
|
---|
620 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
621 | pszOdinDebugChannel)); \
|
---|
622 | FNEPILOGUE \
|
---|
623 | } \
|
---|
624 | \
|
---|
625 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12)
|
---|
626 |
|
---|
627 |
|
---|
628 | /* ---------- 13 parameters ---------- */
|
---|
629 | #define ODINFUNCTION13(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13) \
|
---|
630 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13); \
|
---|
631 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13) \
|
---|
632 | { \
|
---|
633 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
634 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
635 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh" \
|
---|
636 | ", "#t12" "#a12"=%08xh, "#t13" "#a13"=%08xh)", \
|
---|
637 | pszOdinDebugChannel, \
|
---|
638 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13)); \
|
---|
639 | FNPROLOGUE(#cName) \
|
---|
640 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13); \
|
---|
641 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
642 | pszOdinDebugChannel, \
|
---|
643 | rc)); \
|
---|
644 | FNEPILOGUE(#cName) \
|
---|
645 | return rc; \
|
---|
646 | } \
|
---|
647 | \
|
---|
648 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13)
|
---|
649 |
|
---|
650 | #define ODINPROCEDURE13(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13) \
|
---|
651 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13); \
|
---|
652 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13) \
|
---|
653 | { \
|
---|
654 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
655 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
656 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh" \
|
---|
657 | ", "#t12" "#a12"=%08xh, "#t13" "#a13"=%08xh, )", \
|
---|
658 | pszOdinDebugChannel, \
|
---|
659 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13)); \
|
---|
660 | FNPROLOGUE(#cName) \
|
---|
661 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13); \
|
---|
662 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
663 | pszOdinDebugChannel)); \
|
---|
664 | FNEPILOGUE \
|
---|
665 | } \
|
---|
666 | \
|
---|
667 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13)
|
---|
668 |
|
---|
669 |
|
---|
670 | /* ---------- 14 parameters ---------- */
|
---|
671 | #define ODINFUNCTION14(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13,t14,a14) \
|
---|
672 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14); \
|
---|
673 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14) \
|
---|
674 | { \
|
---|
675 | dprintfNoEOL(("%s: "#cRet" "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
676 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
677 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh" \
|
---|
678 | ", "#t12" "#a12"=%08xh, "#t13" "#a13"=%08xh, "#t14" "#a14"=%08xh)", \
|
---|
679 | pszOdinDebugChannel, \
|
---|
680 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13,a14)); \
|
---|
681 | FNPROLOGUE(#cName) \
|
---|
682 | cRet rc = ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13,a14); \
|
---|
683 | dprintf(("%s: "#cRet" "#cName"() leave = %08xh\n", \
|
---|
684 | pszOdinDebugChannel, \
|
---|
685 | rc)); \
|
---|
686 | FNEPILOGUE(#cName) \
|
---|
687 | return rc; \
|
---|
688 | } \
|
---|
689 | \
|
---|
690 | cRet ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14)
|
---|
691 |
|
---|
692 | #define ODINPROCEDURE14(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13,t14,a14) \
|
---|
693 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14); \
|
---|
694 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14) \
|
---|
695 | { \
|
---|
696 | dprintfNoEOL(("%s: void "#cName"("#t1" "#a1"=%08xh, "#t2" "#a2"=%08xh, "#t3" "#a3"=%08xh)" \
|
---|
697 | ", "#t4" "#a4"=%08xh, "#t5" "#a5"=%08xh, "#t6" "#a6"=%08xh, "#t7" "#a7"=%08xh" \
|
---|
698 | ", "#t8" "#a8"=%08xh, "#t9" "#a9"=%08xh, "#t10" "#a10"=%08xh, "#t11" "#a11"=%08xh" \
|
---|
699 | ", "#t12" "#a12"=%08xh, "#t13" "#a13"=%08xh, "#t14" "#a14"=%08xh)", \
|
---|
700 | pszOdinDebugChannel, \
|
---|
701 | a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13,a14)); \
|
---|
702 | FNPROLOGUE(#cName) \
|
---|
703 | ODIN_##cName(a1,a2,a3,a4,a5,a6,a7,a8,a9,a10,a11,a12,a13,a14); \
|
---|
704 | dprintf(("%s: void "#cName"() leave\n", \
|
---|
705 | pszOdinDebugChannel)); \
|
---|
706 | FNEPILOGUE \
|
---|
707 | } \
|
---|
708 | \
|
---|
709 | void ODIN_INTERNAL ODIN_##cName (t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14)
|
---|
710 |
|
---|
711 |
|
---|
712 | #else
|
---|
713 |
|
---|
714 | /****************************************************************************
|
---|
715 | * General Wrapper Macros *
|
---|
716 | ****************************************************************************/
|
---|
717 |
|
---|
718 | #define ODINFUNCTION0 ODINFUNCTIONNODBG0
|
---|
719 | #define ODINFUNCTION1 ODINFUNCTIONNODBG0
|
---|
720 | #define ODINFUNCTION2 ODINFUNCTIONNODBG1
|
---|
721 | #define ODINFUNCTION3 ODINFUNCTIONNODBG2
|
---|
722 | #define ODINFUNCTION4 ODINFUNCTIONNODBG3
|
---|
723 | #define ODINFUNCTION5 ODINFUNCTIONNODBG4
|
---|
724 | #define ODINFUNCTION6 ODINFUNCTIONNODBG5
|
---|
725 | #define ODINFUNCTION7 ODINFUNCTIONNODBG6
|
---|
726 | #define ODINFUNCTION8 ODINFUNCTIONNODBG7
|
---|
727 | #define ODINFUNCTION9 ODINFUNCTIONNODBG8
|
---|
728 | #define ODINFUNCTION10 ODINFUNCTIONNODBG10
|
---|
729 | #define ODINFUNCTION11 ODINFUNCTIONNODBG11
|
---|
730 | #define ODINFUNCTION12 ODINFUNCTIONNODBG12
|
---|
731 | #define ODINFUNCTION13 ODINFUNCTIONNODBG13
|
---|
732 | #define ODINFUNCTION14 ODINFUNCTIONNODBG14
|
---|
733 |
|
---|
734 | #define ODINPROCEDURE0 ODINPROCEDURENODBG0
|
---|
735 | #define ODINPROCEDURE1 ODINPROCEDURENODBG0
|
---|
736 | #define ODINPROCEDURE2 ODINPROCEDURENODBG1
|
---|
737 | #define ODINPROCEDURE3 ODINPROCEDURENODBG2
|
---|
738 | #define ODINPROCEDURE4 ODINPROCEDURENODBG3
|
---|
739 | #define ODINPROCEDURE5 ODINPROCEDURENODBG4
|
---|
740 | #define ODINPROCEDURE6 ODINPROCEDURENODBG5
|
---|
741 | #define ODINPROCEDURE7 ODINPROCEDURENODBG6
|
---|
742 | #define ODINPROCEDURE8 ODINPROCEDURENODBG7
|
---|
743 | #define ODINPROCEDURE9 ODINPROCEDURENODBG8
|
---|
744 | #define ODINPROCEDURE10 ODINPROCEDURENODBG10
|
---|
745 | #define ODINPROCEDURE11 ODINPROCEDURENODBG11
|
---|
746 | #define ODINPROCEDURE12 ODINPROCEDURENODBG12
|
---|
747 | #define ODINPROCEDURE13 ODINPROCEDURENODBG13
|
---|
748 | #define ODINPROCEDURE14 ODINPROCEDURENODBG14
|
---|
749 |
|
---|
750 | #endif
|
---|
751 |
|
---|
752 | /****************************************************************************
|
---|
753 | * General Wrapper Macros *
|
---|
754 | ****************************************************************************/
|
---|
755 |
|
---|
756 | /* ---------- 0 parameters ---------- */
|
---|
757 | #define ODINFUNCTIONNODBG0(cRet,cName) cRet WINAPI cName(void)
|
---|
758 | #define ODINPROCEDURENODBG0(cName) void WINAPI cName(void)
|
---|
759 |
|
---|
760 | /* ---------- 1 parameters ---------- */
|
---|
761 | #define ODINFUNCTIONNODBG1(cRet,cName,t1,a1) cRet WINAPI cName(t1 a1)
|
---|
762 | #define ODINPROCEDURENODBG1(cName,t1,a1) void WINAPI cName(t1 a1)
|
---|
763 |
|
---|
764 | /* ---------- 2 parameters ---------- */
|
---|
765 | #define ODINFUNCTIONNODBG2(cRet,cName,t1,a1,t2,a2) cRet WINAPI cName(t1 a1,t2 a2)
|
---|
766 | #define ODINPROCEDURENODBG2(cName,t1,a1,t2,a2) void WINAPI cName(t1 a1,t2 a2)
|
---|
767 |
|
---|
768 | /* ---------- 3 parameters ---------- */
|
---|
769 | #define ODINFUNCTIONNODBG3(cRet,cName,t1,a1,t2,a2,t3,a3) cRet WINAPI cName(t1 a1,t2 a2,t3 a3)
|
---|
770 | #define ODINPROCEDURENODBG3(cName,t1,a1,t2,a2,t3,a3) void WINAPI cName(t1 a1,t2 a2,t3 a3)
|
---|
771 |
|
---|
772 | /* ---------- 4 parameters ---------- */
|
---|
773 | #define ODINFUNCTIONNODBG4(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4)
|
---|
774 | #define ODINPROCEDURENODBG4(cName,t1,a1,t2,a2,t3,a3,t4,a4) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4)
|
---|
775 |
|
---|
776 | /* ---------- 5 parameters ---------- */
|
---|
777 | #define ODINFUNCTIONNODBG5(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5)
|
---|
778 | #define ODINPROCEDURENODBG5(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5)
|
---|
779 |
|
---|
780 | /* ---------- 6 parameters ---------- */
|
---|
781 | #define ODINFUNCTIONNODBG6(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6)
|
---|
782 | #define ODINPROCEDURENODBG6(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6)
|
---|
783 |
|
---|
784 | /* ---------- 7 parameters ---------- */
|
---|
785 | #define ODINFUNCTIONNODBG7(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7)
|
---|
786 | #define ODINPROCEDURENODBG7(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7)
|
---|
787 |
|
---|
788 | /* ---------- 8 parameters ---------- */
|
---|
789 | #define ODINFUNCTIONNODBG8(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8)
|
---|
790 | #define ODINPROCEDURENODBG8(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8)
|
---|
791 |
|
---|
792 | /* ---------- 9 parameters ---------- */
|
---|
793 | #define ODINFUNCTIONNODBG9(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9)
|
---|
794 | #define ODINPROCEDURENODBG9(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9)
|
---|
795 |
|
---|
796 | /* ---------- 10 parameters ---------- */
|
---|
797 | #define ODINFUNCTIONNODBG10(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10)
|
---|
798 | #define ODINPROCEDURENODBG10(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10)
|
---|
799 |
|
---|
800 | /* ---------- 11 parameters ---------- */
|
---|
801 | #define ODINFUNCTIONNODBG11(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11)
|
---|
802 | #define ODINPROCEDURENODBG11(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11)
|
---|
803 |
|
---|
804 | /* ---------- 12 parameters ---------- */
|
---|
805 | #define ODINFUNCTIONNODBG12(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12) cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12)
|
---|
806 | #define ODINPROCEDURENODBG12(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12) void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12)
|
---|
807 |
|
---|
808 | /* ---------- 13 parameters ---------- */
|
---|
809 | #define ODINFUNCTIONNODBG13(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13) \
|
---|
810 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13)
|
---|
811 |
|
---|
812 | #define ODINPROCEDURENODBG13(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13) \
|
---|
813 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13)
|
---|
814 |
|
---|
815 | /* ---------- 14 parameters ---------- */
|
---|
816 | #define ODINFUNCTIONNODBG14(cRet,cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13,t14,a14) \
|
---|
817 | cRet WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14)
|
---|
818 |
|
---|
819 | #define ODINPROCEDURENODBG14(cName,t1,a1,t2,a2,t3,a3,t4,a4,t5,a5,t6,a6,t7,a7,t8,a8,t9,a9,t10,a10,t11,a11,t12,a12,t13,a13,t14,a14) \
|
---|
820 | void WINAPI cName(t1 a1,t2 a2,t3 a3,t4 a4,t5 a5,t6 a6,t7 a7,t8 a8,t9 a9,t10 a10,t11 a11,t12 a12,t13 a13,t14 a14)
|
---|
821 |
|
---|
822 |
|
---|
823 | #endif /* _ODINWRAP_H_ */
|
---|