HPCToolkit
gpu_ctxt_actions.h
Go to the documentation of this file.
1 #ifndef GPU_CTXT_ACTIONS
2 #define GPU_CTXT_ACTIONS
3 
4 #include <stdint.h>
5 
6 // opaque data type -- so that clients do not have to include entire gpu
7 // API
8 typedef struct cuda_ctxt_t cuda_ctxt_t;
9 
10 // Opaque, atomic context counter ops
11 // reset context counter to 0
12 extern void cuda_ncontexts_reset(void);
13 extern uint64_t cuda_ncontexts_incr(void);
14 extern uint64_t cuda_ncontexts_decr(void);
15 
16 // NOTE: These functions have hidden side effect !!!
17 extern cuda_ctxt_t* cuda_capture_ctxt(void);
18 extern void cuda_set_ctxt(cuda_ctxt_t* ctxt);
19 extern void* cuda_get_handle(cuda_ctxt_t* ctxt);
20 extern void cuda_ncontexts_reset(void);
21 #endif // GPU_CTXT_ACTIONS
void * cuda_get_handle(cuda_ctxt_t *ctxt)
void cuda_ncontexts_reset(void)
cuda_ctxt_t * cuda_capture_ctxt(void)
CUcontext ctxt
void cuda_set_ctxt(cuda_ctxt_t *ctxt)
uint64_t cuda_ncontexts_incr(void)
uint64_t cuda_ncontexts_decr(void)