ompt-internal.h

Go to the documentation of this file.
00001 #ifndef __OMPT_INTERNAL_H__
00002 #define __OMPT_INTERNAL_H__
00003 
00004 #include "ompt.h"
00005 #include "ompt-event-specific.h"
00006 
00007 #define OMPT_VERSION 1
00008 
00009 #define _OMP_EXTERN
00010 
00011 
00012 
00013 #define ompt_callback(e) e ## _callback
00014 
00015 /* track and track_callback share a bit so that one can test whether either is set 
00016  * by anding a bit.
00017  */
00018 typedef enum {
00019   ompt_status_disabled       = 0x0,
00020   ompt_status_ready          = 0x1,
00021   ompt_status_track          = 0x2,
00022   ompt_status_track_callback = 0x6,
00023 } ompt_status_t;
00024 
00025 
00026 typedef struct ompt_callbacks_s {
00027 #define ompt_event(event, callback, eventid, is_impl) callback ompt_callback(event); 
00028 #include "ompt-event.h"
00029 } ompt_callbacks_t;
00030 
00031 
00032 typedef struct {
00033   ompt_frame_t        frame;
00034   ompt_task_id_t      task_id;
00035 } ompt_task_info_t;
00036 
00037 
00038 typedef struct {
00039   ompt_parallel_id_t  parallel_id;
00040   void                *microtask;
00041 } ompt_team_info_t;
00042 
00043 
00044 typedef struct ompt_lw_taskteam_s {
00045   ompt_team_info_t    ompt_team_info;
00046   ompt_task_info_t    ompt_task_info;
00047   struct ompt_lw_taskteam_s *parent;  
00048 } ompt_lw_taskteam_t;
00049 
00050 
00051 typedef struct ompt_parallel_info_s {
00052   ompt_task_id_t parent_task_id;    /* id of parent task            */
00053   ompt_frame_t *parent_task_frame;  /* frame data of parent task    */
00054   ompt_parallel_id_t parallel_id;   /* id of parallel region        */
00055   void *parallel_function;          /* pointer to outlined function */
00056 } ompt_parallel_info_t;
00057 
00058 
00059 typedef struct {
00060   ompt_state_t        prev_state;
00061   ompt_state_t        state;
00062   ompt_wait_id_t      wait_id;
00063   uint64_t            next_parallel_id;
00064   uint64_t            next_task_id;
00065   void                *idle_frame;
00066   ompt_lw_taskteam_t  *lw_taskteam;  
00067 } ompt_thread_info_t;
00068 
00069 
00070 extern ompt_status_t ompt_status;
00071 extern ompt_callbacks_t ompt_callbacks;
00072 
00073 #ifdef __cplusplus
00074 extern "C" {
00075 #endif
00076 
00077 void ompt_init(void);
00078 void ompt_fini(void);
00079 
00080 #ifdef __cplusplus
00081 };
00082 #endif
00083 
00084 #endif

Generated on 25 Aug 2013 for libomp_oss by  doxygen 1.6.1