#include "RtsProbes.h"
#endif /* defined(DTRACE) */
-BEGIN_RTS_PRIVATE
+#include "BeginPrivate.h"
// -----------------------------------------------------------------------------
// EventLog API
void initTracing (void);
void endTracing (void);
void freeTracing (void);
+void resetTracing (void);
#endif /* TRACING */
#define debugTrace(class, str, ...) /* nothing */
#endif
+#ifdef DEBUG
+#define debugTraceCap(class, cap, msg, ...) \
+ if (RTS_UNLIKELY(class)) { \
+ traceCap_(cap, msg, ##__VA_ARGS__); \
+ }
+#else
+#define debugTraceCap(class, cap, str, ...) /* nothing */
+#endif
+
/*
* Emit a message/event describing the state of a thread
*/
#define traceCap(class, cap, msg, ...) /* nothing */
#define trace(class, msg, ...) /* nothing */
#define debugTrace(class, str, ...) /* nothing */
+#define debugTraceCap(class, cap, str, ...) /* nothing */
#define traceThreadStatus(class, tso) /* nothing */
#endif /* TRACING */
INLINE_HEADER void traceEventCreateThread(Capability *cap STG_UNUSED,
StgTSO *tso STG_UNUSED)
{
- traceSchedEvent(cap, EVENT_CREATE_THREAD, tso, tso->stack_size);
+ traceSchedEvent(cap, EVENT_CREATE_THREAD, tso, tso->stackobj->stack_size);
dtraceCreateThread((EventCapNo)cap->no, (EventThreadID)tso->id);
}
dtraceGcDone((EventCapNo)cap->no);
}
-END_RTS_PRIVATE
+#include "EndPrivate.h"
#endif /* TRACE_H */