Commit | Line | Data |
---|---|---|
cd84c2ac | 1 | /* For debugging general purposes */ |
8b40f521 JK |
2 | #ifndef __PERF_DEBUG_H |
3 | #define __PERF_DEBUG_H | |
cd84c2ac | 4 | |
8f41146a ACM |
5 | #include "event.h" |
6 | ||
cd84c2ac | 7 | extern int verbose; |
2cec19d9 | 8 | extern int dump_trace; |
cd84c2ac | 9 | |
2cec19d9 | 10 | int dump_printf(const char *fmt, ...) __attribute__((format(printf, 1, 2))); |
8f28827a | 11 | void trace_event(event_t *event); |
567e5479 | 12 | |
5f4d3f88 ACM |
13 | struct ui_progress; |
14 | ||
567e5479 ACM |
15 | #ifdef NO_NEWT_SUPPORT |
16 | static inline int browser__show_help(const char *format __used, va_list ap __used) | |
17 | { | |
18 | return 0; | |
19 | } | |
5f4d3f88 ACM |
20 | |
21 | static inline struct ui_progress *ui_progress__new(const char *title __used, | |
22 | u64 total __used) | |
23 | { | |
24 | return (struct ui_progress *)1; | |
25 | } | |
26 | ||
27 | static inline void ui_progress__update(struct ui_progress *self __used, | |
28 | u64 curr __used) {} | |
29 | ||
30 | static inline void ui_progress__delete(struct ui_progress *self __used) {} | |
567e5479 | 31 | #else |
f9224c5c | 32 | int browser__show_help(const char *format, va_list ap); |
5f4d3f88 ACM |
33 | struct ui_progress *ui_progress__new(const char *title, u64 total); |
34 | void ui_progress__update(struct ui_progress *self, u64 curr); | |
35 | void ui_progress__delete(struct ui_progress *self); | |
567e5479 | 36 | #endif |
8b40f521 JK |
37 | |
38 | #endif /* __PERF_DEBUG_H */ |