diff options
| author | Mengchi Zhang <[email protected]> | 2019-06-12 13:02:19 -0400 |
|---|---|---|
| committer | GitHub <[email protected]> | 2019-06-12 13:02:19 -0400 |
| commit | c5578dade2fef7985bf1b26a7f3ae78896c96b69 (patch) | |
| tree | f92e42961c0fda60a5f22383490831dcf1cc900b /libcuda/cuda_api_object.h | |
| parent | 35b55f5313d079327be9e6c91de5a53a01030e3e (diff) | |
| parent | 7a6ff7084c1c65450775b4d58e80f8c789888815 (diff) | |
Merge pull request #16 from echoedit/dev
Dev
Diffstat (limited to 'libcuda/cuda_api_object.h')
| -rw-r--r-- | libcuda/cuda_api_object.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libcuda/cuda_api_object.h b/libcuda/cuda_api_object.h index d931fd5..0054697 100644 --- a/libcuda/cuda_api_object.h +++ b/libcuda/cuda_api_object.h @@ -171,6 +171,7 @@ class cuda_runtime_api { public: cuda_runtime_api() { g_glbmap = NULL; + g_active_device = 0; //active gpu that runs the code } // global list std::list<cuobjdumpSection*> cuobjdumpSectionList; @@ -185,11 +186,11 @@ class cuda_runtime_api { std::map<void *,void **> pinned_memory; //support for pinned memories added std::map<void *, size_t> pinned_memory_size; glbmap_entry_t* g_glbmap; + int g_active_device; //active gpu that runs the code // member function list void cuobjdumpInit(); void extract_code_using_cuobjdump(); void extract_ptx_files_using_cuobjdump(CUctx_st *context); - void cuobjdumpParseBinary(unsigned int handle); std::list<cuobjdumpSection*> pruneSectionList(CUctx_st *context); std::list<cuobjdumpSection*> mergeMatchingSections(std::string identifier); std::list<cuobjdumpSection*> mergeSections(); @@ -201,5 +202,8 @@ class cuda_runtime_api { struct dim3 gridDim, struct dim3 blockDim, struct CUctx_st* context ); + int load_static_globals( symbol_table *symtab, unsigned min_gaddr, unsigned max_gaddr, gpgpu_t *gpu ); + int load_constants( symbol_table *symtab, addr_t min_gaddr, gpgpu_t *gpu ); + }; #endif /* __cuda_api_object_h__ */ |
