trace.h
1.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/*************************************************************************
*
* File: trace.h
*
* Header file for tracing facility
*
* $Header: /root/leakn64/depot/rf/sw/n64os20l/lib/librcppli/trace.h,v 1.1.1.2 2002/10/29 08:06:41 blythe Exp $
*
*/
#ifndef _TRACE_H_
#define _TRACE_H_
#ifdef DEBUG
extern unsigned long Dflags; /* Global debug flag */
/* Debug flag settings */
#define DALL 0xFFFFFFFF /* Turn on all debug types */
#define DERROR 0x00000001 /* Turn on error tracing */
#define DREAD 0x00000002 /* Turn on read tracing */
#define DWRITE 0x00000004 /* Turn on write tracing */
#define DSIGNAL 0x00000008 /* Turn on signal tracing */
#define DINST 0x00000010 /* Turn on instruction tracing */
#define DREGS 0x00000020 /* Turn on register tracing */
#define DLOG 0x00000040 /* Turn on log tracing */
#define DTRANS 0x00000080 /* Turn on IO R/W tracing */
#define DSTATUS 0x00000100 /* Turn on status tracing */
#define DCOMPARE 0x00000200 /* Turn on data compare tracing */
#define _TRACE(type, code) { if (Dflags & (type)) code; }
#else
#define _TRACE(type, code)
#endif
#endif /* _TRACE_H_ */