Home | History | Annotate | Line # | Download | only in internal
      1  1.1  christos #ifndef JEMALLOC_INTERNAL_JEMALLOC_PROBE_H
      2  1.1  christos #define JEMALLOC_INTERNAL_JEMALLOC_PROBE_H
      3  1.1  christos 
      4  1.1  christos #include <jemalloc/internal/jemalloc_preamble.h>
      5  1.1  christos 
      6  1.1  christos #ifdef JEMALLOC_EXPERIMENTAL_USDT_STAP
      7  1.1  christos #include <jemalloc/internal/jemalloc_probe_stap.h>
      8  1.1  christos #elif defined(JEMALLOC_EXPERIMENTAL_USDT_CUSTOM)
      9  1.1  christos #include <jemalloc/internal/jemalloc_probe_custom.h>
     10  1.1  christos #elif defined(_MSC_VER)
     11  1.1  christos #define JE_USDT(name, N, ...) /* Nothing */
     12  1.1  christos #else /*  no USDT, just check the args */
     13  1.1  christos 
     14  1.1  christos #define JE_USDT(name, N, ...) _JE_USDT_CHECK_ARG##N(__VA_ARGS__)
     15  1.1  christos 
     16  1.1  christos #define _JE_USDT_CHECK_ARG1(a)						\
     17  1.1  christos 	do {								\
     18  1.1  christos 		/*LINTED*/(void)(a);						\
     19  1.1  christos 	} while (0)
     20  1.1  christos #define _JE_USDT_CHECK_ARG2(a, b)					\
     21  1.1  christos 	do {								\
     22  1.1  christos 		/*LINTED*/(void)(a);						\
     23  1.1  christos 		/*LINTED*/(void)(b);						\
     24  1.1  christos 	} while (0)
     25  1.1  christos #define _JE_USDT_CHECK_ARG3(a, b, c)					\
     26  1.1  christos 	do {								\
     27  1.1  christos 		/*LINTED*/(void)(a);						\
     28  1.1  christos 		/*LINTED*/(void)(b);						\
     29  1.1  christos 		/*LINTED*/(void)(c);						\
     30  1.1  christos 	} while (0)
     31  1.1  christos #define _JE_USDT_CHECK_ARG4(a, b, c, d)					\
     32  1.1  christos 	do {								\
     33  1.1  christos 		/*LINTED*/(void)(a);						\
     34  1.1  christos 		/*LINTED*/(void)(b);						\
     35  1.1  christos 		/*LINTED*/(void)(c);						\
     36  1.1  christos 		/*LINTED*/(void)(d);						\
     37  1.1  christos 	} while (0)
     38  1.1  christos #define _JE_USDT_CHECK_ARG5(a, b, c, d, e)				\
     39  1.1  christos 	do {								\
     40  1.1  christos 		/*LINTED*/(void)(a);						\
     41  1.1  christos 		/*LINTED*/(void)(b);						\
     42  1.1  christos 		/*LINTED*/(void)(c);						\
     43  1.1  christos 		/*LINTED*/(void)(d);						\
     44  1.1  christos 		/*LINTED*/(void)(e);						\
     45  1.1  christos 	} while (0)
     46  1.1  christos 
     47  1.1  christos #endif /* JEMALLOC_EXPERIMENTAL_USDT_* */
     48  1.1  christos 
     49  1.1  christos #endif /* JEMALLOC_INTERNAL_JEMALLOC_PROBE_H */
     50