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 |
21 |
26 |
22 |
27 |
23 /** |
28 /** |
24 Methods for tracing from user side. |
29 Methods for tracing from user side. |
25 |
30 |
115 This should not be used from traces |
120 This should not be used from traces |
116 */ |
121 */ |
117 #define OST_TRACE_CATEGORY_NONE 0x00000000 |
122 #define OST_TRACE_CATEGORY_NONE 0x00000000 |
118 |
123 |
119 /** |
124 /** |
120 Preprocessor category for production traces |
125 Preprocessor category for traces that should be compiled |
|
126 into all builds including UREL. As a result these traces |
|
127 will end up in production images used by consumers. |
121 */ |
128 */ |
122 #define OST_TRACE_CATEGORY_PRODUCTION 0x00000001 |
129 #define OST_TRACE_CATEGORY_PRODUCTION 0x00000001 |
123 |
130 |
124 /** |
131 /** |
125 Preprocessor category for RnD traces |
132 Preprocessor category for RnD traces |
128 |
135 |
129 /** |
136 /** |
130 Preprocessor category for performance measurement traces |
137 Preprocessor category for performance measurement traces |
131 */ |
138 */ |
132 #define OST_TRACE_CATEGORY_PERFORMANCE_MEASUREMENT 0x00000004 |
139 #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 |
133 |
146 |
134 /** |
147 /** |
135 Preprocessor level for all traces on. |
148 Preprocessor level for all traces on. |
136 This should not be used from traces |
149 This should not be used from traces |
137 */ |
150 */ |
143 */ |
156 */ |
144 #if defined( OST_TRACE_COMPILER_IN_USE ) |
157 #if defined( OST_TRACE_COMPILER_IN_USE ) |
145 |
158 |
146 |
159 |
147 /** |
160 /** |
148 The default preprocessor category is RND |
161 The default preprocessor categories are defined here. |
149 Component may override this by defining |
162 A component may override this by defining |
150 OST_TRACE_CATEGORY before including this file |
163 OST_TRACE_CATEGORY before including this file |
151 */ |
164 |
152 #if !defined( OST_TRACE_CATEGORY ) |
165 The RND category is defined for UREL and UDEB to |
153 #define OST_TRACE_CATEGORY OST_TRACE_CATEGORY_RND |
166 preserve source compatibility. |
154 #endif |
167 */ |
|
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 |
155 |
179 |
156 /** |
180 /** |
157 Trace with no parameters |
181 Trace with no parameters |
158 |
182 |
159 @param aCategory Preprocessor category for the trace |
183 @param aCategory Preprocessor category for the trace |