14 #ifndef SION_SION_DEBUG_H
15 #define SION_SION_DEBUG_H
19 #define _SION_DEFAULT_RANK -1
28 #define ONLY_DEBUG(A) A
29 #define DPRINTF(A) sion_dprintf A
30 #define DPRINTFP(A) sion_dprintfp A
31 #define DPRINTFTS(rank,desc) sion_dprintfp(128,"TIMING",rank," step=%-40s timestamp=%18.8f\n",desc,_sion_get_time())
32 #define DPRINTFTS2(rank,desc) sion_dprintfp(256,"TIMING",rank," step=%-40s timestamp=%18.8f\n",desc,_sion_get_time())
37 #define DPRINTFTS(A,B)
38 #define DPRINTFTS2(A,B)
47 int sion_dprintfp(
int mask,
const char *callfunction,
int rank,
const char *format, ...);
48 int sion_isdebug(
void);
50 void sion_debug_off(
void);
54 void _sion_debug_set_lock_cb(
void (*set_lock)(
void),
void (*unset_lock)(
void));
56 int _sion_debug_set_query_thread_num_function(
int (*get_thread_num)(
void) );
int sion_dprintfp(int mask, const char *callfunction, int rank, const char *format,...)
Print debugging info formating the message like printf and including the name of the calling function...
FILE * sion_get_dfile(void)
int _sion_debug_init(void)
initialize the debug environment
void sion_debug_on(int mask, const char *filename)
sets debug mode.
int sion_dprintf(int mask, const char *format,...)
Print debugging info formating the message like printf.