X-Git-Url: http://git.liburcu.org/?a=blobdiff_plain;f=rcuja%2Frcuja-internal.h;fp=rcuja%2Frcuja-internal.h;h=18ad288a4a4973c9336093adb62bfd84e55715d1;hb=f83b3e90613a55a9f5dda7a71839c3930a47d96a;hp=8afe0a436c521b6983dc14e5cc64ad21aacfe60c;hpb=747688b527aef42c5538b6c8b61b39f255a29d54;p=userspace-rcu.git diff --git a/rcuja/rcuja-internal.h b/rcuja/rcuja-internal.h index 8afe0a4..18ad288 100644 --- a/rcuja/rcuja-internal.h +++ b/rcuja/rcuja-internal.h @@ -223,6 +223,7 @@ void free_cds_ja_node(struct cds_ja *ja, struct cds_ja_inode *node); for (; (pos) != NULL; (pos) = (pos)->next) //#define DEBUG +//#define DEBUG_COUNTERS #ifdef __linux__ #include @@ -248,6 +249,7 @@ static inline pid_t gettid(void) fprintf(stderr, "[debug rcuja %lu %s()@%s:%u] " fmt, \ (unsigned long) gettid(), __func__, \ __FILE__, __LINE__, ## args) + #else #define dbg_printf(fmt, args...) \ do { \ @@ -259,4 +261,18 @@ do { \ } while (0) #endif +#ifdef DEBUG_COUNTERS +static inline +ja_debug_counters(void) +{ + return 1; +} +#else +static inline +ja_debug_counters(void) +{ + return 0; +} +#endif + #endif /* _URCU_RCUJA_INTERNAL_H */