equal
deleted
inserted
replaced
16 |
16 |
17 #ifndef OPENSYSTEMTRACEV2_H |
17 #ifndef OPENSYSTEMTRACEV2_H |
18 #define OPENSYSTEMTRACEV2_H |
18 #define OPENSYSTEMTRACEV2_H |
19 |
19 |
20 #include <opensystemtrace_types.h> |
20 #include <opensystemtrace_types.h> |
21 |
|
22 /** |
|
23 This macro defines the version of the Open System Trace instrumentation API. |
|
24 */ |
|
25 #define OST_INSTRUMENTATION_API_VERSION 2.1.0 |
|
26 |
21 |
27 |
22 |
28 /** |
23 /** |
29 Methods for tracing from user side. |
24 Methods for tracing from user side. |
30 |
25 |
120 This should not be used from traces |
115 This should not be used from traces |
121 */ |
116 */ |
122 #define OST_TRACE_CATEGORY_NONE 0x00000000 |
117 #define OST_TRACE_CATEGORY_NONE 0x00000000 |
123 |
118 |
124 /** |
119 /** |
125 Preprocessor category for traces that should be compiled |
120 Preprocessor category for production traces |
126 into all builds including UREL. As a result these traces |
|
127 will end up in production images used by consumers. |
|
128 */ |
121 */ |
129 #define OST_TRACE_CATEGORY_PRODUCTION 0x00000001 |
122 #define OST_TRACE_CATEGORY_PRODUCTION 0x00000001 |
130 |
123 |
131 /** |
124 /** |
132 Preprocessor category for RnD traces |
125 Preprocessor category for RnD traces |
135 |
128 |
136 /** |
129 /** |
137 Preprocessor category for performance measurement traces |
130 Preprocessor category for performance measurement traces |
138 */ |
131 */ |
139 #define OST_TRACE_CATEGORY_PERFORMANCE_MEASUREMENT 0x00000004 |
132 #define OST_TRACE_CATEGORY_PERFORMANCE_MEASUREMENT 0x00000004 |
140 |
|
141 /** |
|
142 Preprocessor category for traces that by default should only |
|
143 be compiled into UDEB builds. |
|
144 */ |
|
145 #define OST_TRACE_CATEGORY_DEBUG 0x00000008 |
|
146 |
133 |
147 /** |
134 /** |
148 Preprocessor level for all traces on. |
135 Preprocessor level for all traces on. |
149 This should not be used from traces |
136 This should not be used from traces |
150 */ |
137 */ |
156 */ |
143 */ |
157 #if defined( OST_TRACE_COMPILER_IN_USE ) |
144 #if defined( OST_TRACE_COMPILER_IN_USE ) |
158 |
145 |
159 |
146 |
160 /** |
147 /** |
161 The default preprocessor categories are defined here. |
148 The default preprocessor category is RND |
162 A component may override this by defining |
149 Component may override this by defining |
163 OST_TRACE_CATEGORY before including this file |
150 OST_TRACE_CATEGORY before including this file |
164 |
151 */ |
165 The RND category is defined for UREL and UDEB to |
152 #if !defined( OST_TRACE_CATEGORY ) |
166 preserve source compatibility. |
153 #define OST_TRACE_CATEGORY OST_TRACE_CATEGORY_RND |
167 */ |
154 #endif |
168 #ifndef OST_TRACE_CATEGORY |
|
169 #ifdef _DEBUG |
|
170 #define OST_TRACE_CATEGORY (OST_TRACE_CATEGORY_RND | \ |
|
171 OST_TRACE_CATEGORY_PRODUCTION | \ |
|
172 OST_TRACE_CATEGORY_DEBUG) |
|
173 #else // _DEBUG |
|
174 #define OST_TRACE_CATEGORY (OST_TRACE_CATEGORY_RND | \ |
|
175 OST_TRACE_CATEGORY_PRODUCTION) |
|
176 #endif // _DEBUG |
|
177 #endif // OST_TRACE_CATEGORY |
|
178 |
|
179 |
155 |
180 /** |
156 /** |
181 Trace with no parameters |
157 Trace with no parameters |
182 |
158 |
183 @param aCategory Preprocessor category for the trace |
159 @param aCategory Preprocessor category for the trace |