diff options
Diffstat (limited to 'nerv/lib/matrix/cumatrix.c')
-rw-r--r-- | nerv/lib/matrix/cumatrix.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/nerv/lib/matrix/cumatrix.c b/nerv/lib/matrix/cumatrix.c index ff1168d..a5991ab 100644 --- a/nerv/lib/matrix/cumatrix.c +++ b/nerv/lib/matrix/cumatrix.c @@ -7,6 +7,8 @@ static cublasHandle_t cublas_handle; static cudaEvent_t profile_start, profile_stop; static HashMap *profile; +const char *nerv_context_tname = "nerv.CCuContext"; + void nerv_cumatrix_print_profile() { size_t i; fprintf(stderr, "*** [nerv cumatrix profile] **\n"); @@ -35,6 +37,12 @@ void accu_profile(const char *name, float delta) { *val += delta; } +cublasHandle_t* nerv_get_cublas_handle() +{ + return &cublas_handle; +} + + void nerv_cumatrix_init() { cublasCreate(&cublas_handle); cudaEventCreate(&profile_start); |