HPCToolkit
monitor_ext.h File Reference
#include <pthread.h>
#include <messages/messages.h>
#include <dlfcn.h>
Include dependency graph for monitor_ext.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define RTLD_NEXT   ((void *) -1L)
 
#define MONITOR_EXT_GET_DLSYM(var, name)
 
#define MONITOR_EXT_WRAP_NAME(name)   name
 
#define MONITOR_EXT_GET_NAME(var, name)   MONITOR_EXT_GET_DLSYM(var, name)
 
#define MONITOR_EXT_GET_NAME_WRAP(var, name)   MONITOR_EXT_GET_DLSYM(var, name)
 
#define MONITOR_EXT_DECLARE_REAL_FN(type, realname)   static type * realname = NULL
 

Macro Definition Documentation

◆ MONITOR_EXT_DECLARE_REAL_FN

#define MONITOR_EXT_DECLARE_REAL_FN (   type,
  realname 
)    static type * realname = NULL

Definition at line 96 of file monitor_ext.h.

◆ MONITOR_EXT_GET_DLSYM

#define MONITOR_EXT_GET_DLSYM (   var,
  name 
)
Value:
do { \
if (var == NULL) { \
const char *err_str; \
dlerror(); \
var = dlsym(RTLD_NEXT, #name ); \
err_str = dlerror(); \
if (var == NULL) { \
hpcrun_abort("dlsym(%s) failed: %s", #name , err_str); \
} \
TMSG(MONITOR_EXTS, "%s() = %p", #name , var); \
} \
} while (0)
#define RTLD_NEXT
Definition: monitor_ext.h:76
#define NULL
Definition: ElfHelper.cpp:85

Definition at line 79 of file monitor_ext.h.

◆ MONITOR_EXT_GET_NAME

#define MONITOR_EXT_GET_NAME (   var,
  name 
)    MONITOR_EXT_GET_DLSYM(var, name)

Definition at line 93 of file monitor_ext.h.

◆ MONITOR_EXT_GET_NAME_WRAP

#define MONITOR_EXT_GET_NAME_WRAP (   var,
  name 
)    MONITOR_EXT_GET_DLSYM(var, name)

Definition at line 94 of file monitor_ext.h.

◆ MONITOR_EXT_WRAP_NAME

#define MONITOR_EXT_WRAP_NAME (   name)    name

Definition at line 92 of file monitor_ext.h.

◆ RTLD_NEXT

#define RTLD_NEXT   ((void *) -1L)

Definition at line 76 of file monitor_ext.h.