HEaaN
Crypto Lab's great homomorphic encryption library
CudaTools.hpp
Go to the documentation of this file.
1 // //
3 // Copyright (C) 2021-2023 Crypto Lab Inc. //
4 // //
5 // - This file is part of HEaaN homomorphic encryption library. //
6 // - HEaaN cannot be copied and/or distributed without the express permission //
7 // of Crypto Lab Inc. //
8 // //
10 
11 #pragma once
12 
13 #include "HEaaN/HEaaNExport.hpp"
14 #include "HEaaN/Integers.hpp"
15 #include <utility>
16 
17 namespace HEaaN::CudaTools {
18 
19 HEAAN_API bool isAvailable();
23 HEAAN_API void cudaSetDevice(int device_id);
24 HEAAN_API void nvtxPush(const char *msg);
25 HEAAN_API void nvtxPop(void);
26 // Return [free, total] memory bytes of the current CUDA device.
27 HEAAN_API std::pair<u64, u64> getCudaMemoryInfo();
28 
29 } // namespace HEaaN::CudaTools
HEaaN::CudaTools::nvtxPop
HEAAN_API void nvtxPop(void)
HEaaN::CudaTools::isAvailable
HEAAN_API bool isAvailable()
HEaaN::CudaTools::cudaGetDeviceCount
HEAAN_API int cudaGetDeviceCount()
HEaaN::CudaTools::getCudaMemoryInfo
HEAAN_API std::pair< u64, u64 > getCudaMemoryInfo()
HEaaN::CudaTools::cudaGetDevice
HEAAN_API int cudaGetDevice()
HEaaN::CudaTools::nvtxPush
HEAAN_API void nvtxPush(const char *msg)
Integers.hpp
HEaaN::CudaTools
Definition: CudaTools.hpp:17
HEaaN::CudaTools::cudaDeviceSynchronize
HEAAN_API void cudaDeviceSynchronize()
HEaaN::CudaTools::cudaSetDevice
HEAAN_API void cudaSetDevice(int device_id)
HEaaNExport.hpp
HEAAN_API
#define HEAAN_API
Definition: HEaaNExport.hpp:26