Do some CUDA and NVRTC version checks on startup

This commit is contained in:
Jens Steube
2019-06-05 10:53:48 +02:00
parent 03ed89684e
commit 44ecc83d82
4 changed files with 72 additions and 18 deletions
+1
View File
@@ -38,6 +38,7 @@ int hc_nvrtcGetProgramLogSize (hashcat_ctx_t *hashcat_ctx, nvrtcProgram prog,
int hc_nvrtcGetProgramLog (hashcat_ctx_t *hashcat_ctx, nvrtcProgram prog, char *log);
int hc_nvrtcGetPTXSize (hashcat_ctx_t *hashcat_ctx, nvrtcProgram prog, size_t *ptxSizeRet);
int hc_nvrtcGetPTX (hashcat_ctx_t *hashcat_ctx, nvrtcProgram prog, char *ptx);
int hc_nvrtcVersion (hashcat_ctx_t *hashcat_ctx, int *major, int *minor);
int hc_cuCtxCreate (hashcat_ctx_t *hashcat_ctx, CUcontext *pctx, unsigned int flags, CUdevice dev);
int hc_cuCtxDestroy (hashcat_ctx_t *hashcat_ctx, CUcontext ctx);
+2
View File
@@ -60,6 +60,7 @@ typedef nvrtcResult (NVRTC_API_CALL *NVRTC_NVRTCGETPTXSIZE) (nvrtcProgr
typedef nvrtcResult (NVRTC_API_CALL *NVRTC_NVRTCGETPROGRAMLOG) (nvrtcProgram, char *);
typedef nvrtcResult (NVRTC_API_CALL *NVRTC_NVRTCGETPROGRAMLOGSIZE) (nvrtcProgram, size_t *);
typedef const char * (NVRTC_API_CALL *NVRTC_NVRTCGETERRORSTRING) (nvrtcResult);
typedef nvrtcResult (NVRTC_API_CALL *NVRTC_NVRTCVERSION) (int *, int *);
typedef struct hc_nvrtc_lib
{
@@ -75,6 +76,7 @@ typedef struct hc_nvrtc_lib
NVRTC_NVRTCGETPROGRAMLOG nvrtcGetProgramLog;
NVRTC_NVRTCGETPROGRAMLOGSIZE nvrtcGetProgramLogSize;
NVRTC_NVRTCGETERRORSTRING nvrtcGetErrorString;
NVRTC_NVRTCVERSION nvrtcVersion;
} hc_nvrtc_lib_t;
+1
View File
@@ -1448,6 +1448,7 @@ typedef struct backend_ctx
// cuda
int nvrtc_driver_version;
int cuda_driver_version;
// opencl