5 #ifndef __MONO_UTILS_MONO_THREADS_DEBUG_H__
6 #define __MONO_UTILS_MONO_THREADS_DEBUG_H__
8 /* Logging - enable them below if you need specific logging for the category you need */
9 #define MOSTLY_ASYNC_SAFE_PRINTF(...) do { \
10 char __buff[1024]; __buff [0] = '\0'; \
11 g_snprintf (__buff, sizeof (__buff), __VA_ARGS__); \
12 write (1, __buff, strlen (__buff)); \
16 #define THREADS_DEBUG(...)
18 #define THREADS_DEBUG MOSTLY_ASYNC_SAFE_PRINTF
22 #define THREADS_STW_DEBUG(...)
24 #define THREADS_STW_DEBUG MOSTLY_ASYNC_SAFE_PRINTF
28 #define THREADS_SUSPEND_DEBUG(...)
30 #define THREADS_SUSPEND_DEBUG MOSTLY_ASYNC_SAFE_PRINTF
34 #define THREADS_STATE_MACHINE_DEBUG(...)
36 #define THREADS_STATE_MACHINE_DEBUG MOSTLY_ASYNC_SAFE_PRINTF
40 #define THREADS_INTERRUPT_DEBUG(...)
42 #define THREADS_INTERRUPT_DEBUG MOSTLY_ASYNC_SAFE_PRINTF
45 #endif /* __MONO_UTILS_MONO_THREADS_DEBUG_H__ */