OpenCL 1.2 is supported in the Linux Nvidia drivers now

This commit is contained in:
Gambhiro 2015-12-15 16:26:22 +00:00
parent 994c05ba68
commit 7318bff32c
2 changed files with 9 additions and 3 deletions

View File

@ -51,9 +51,12 @@ macx {
QMAKE_LFLAGS_RELEASE += -s QMAKE_LFLAGS_RELEASE += -s
} }
nvidia { # The NVIDIA def was used to force OpenCL 1.1.
QMAKE_CXXFLAGS += -DNVIDIA # The Linux drivers support OpenCL 1.2 now.
}
#nvidia {
# QMAKE_CXXFLAGS += -DNVIDIA
#}
native { native {
QMAKE_CXXFLAGS += -march=native QMAKE_CXXFLAGS += -march=native

View File

@ -24,6 +24,8 @@
#include <utility> #include <utility>
// OpenCL 1.2 is supported in the Linux Nvidia drivers now.
/*
#ifdef NVIDIA #ifdef NVIDIA
#ifdef CL_VERSION_1_2 #ifdef CL_VERSION_1_2
#undef CL_VERSION_1_2 #undef CL_VERSION_1_2
@ -35,6 +37,7 @@
#endif #endif
#endif #endif
#endif #endif
*/
#include <CL/cl.hpp> #include <CL/cl.hpp>