mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-01-26 11:04:33 +00:00
CUDA: Update CUDA tests to handle CUDA 13 deprecations
This commit is contained in:
parent
bbf732525a
commit
3ff777de12
@ -36,7 +36,14 @@ int main()
|
||||
cuDeviceGet(&device, 0);
|
||||
|
||||
CUcontext context;
|
||||
#if defined(__CUDACC_VER_MAJOR__) && __CUDACC_VER_MAJOR__ >= 13
|
||||
CUctxCreateParams params;
|
||||
params.execAffinityParams = nullptr;
|
||||
params.numExecAffinityParams = 0;
|
||||
cuCtxCreate(&context, ¶ms, 0, device);
|
||||
#else
|
||||
cuCtxCreate(&context, 0, device);
|
||||
#endif
|
||||
|
||||
CUmodule module;
|
||||
for (auto p : actual_paths) {
|
||||
|
||||
@ -36,8 +36,14 @@ int main()
|
||||
cuDeviceGet(&device, 0);
|
||||
|
||||
CUcontext context;
|
||||
#if defined(__CUDACC_VER_MAJOR__) && __CUDACC_VER_MAJOR__ >= 13
|
||||
CUctxCreateParams params;
|
||||
params.execAffinityParams = nullptr;
|
||||
params.numExecAffinityParams = 0;
|
||||
cuCtxCreate(&context, ¶ms, 0, device);
|
||||
#else
|
||||
cuCtxCreate(&context, 0, device);
|
||||
|
||||
#endif
|
||||
CUmodule module;
|
||||
for (auto p : actual_paths) {
|
||||
if (p.find(".fatbin") == std::string::npos) {
|
||||
|
||||
@ -18,7 +18,14 @@ int main()
|
||||
cuDeviceGet(&device, 0);
|
||||
|
||||
CUcontext context;
|
||||
#if defined(__CUDACC_VER_MAJOR__) && __CUDACC_VER_MAJOR__ >= 13
|
||||
CUctxCreateParams params;
|
||||
params.execAffinityParams = nullptr;
|
||||
params.numExecAffinityParams = 0;
|
||||
cuCtxCreate(&context, ¶ms, 0, device);
|
||||
#else
|
||||
cuCtxCreate(&context, 0, device);
|
||||
#endif
|
||||
|
||||
CUmodule module;
|
||||
CUresult result = cuModuleLoadData(&module, kernels);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user