clover: Fix build after clang r367864

Submitted by Jan Vesely on Aug. 6, 2019, 5:47 p.m.

Details

Message ID 20190806174733.5721-1-jan.vesely@rutgers.edu
State New
Headers show
Series "clover: Fix build after clang r367864" ( rev: 1 ) in Mesa

Not browsing as part of any series.

Commit Message

Jan Vesely Aug. 6, 2019, 5:47 p.m.
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
---
 src/gallium/state_trackers/clover/llvm/compat.hpp | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

Patch hide | download patch | download mbox

diff --git a/src/gallium/state_trackers/clover/llvm/compat.hpp b/src/gallium/state_trackers/clover/llvm/compat.hpp
index 0ecf622a9af..b273abf75af 100644
--- a/src/gallium/state_trackers/clover/llvm/compat.hpp
+++ b/src/gallium/state_trackers/clover/llvm/compat.hpp
@@ -79,11 +79,19 @@  namespace clover {
 #endif
          }
 
-#if HAVE_LLVM >= 0x0500
+#if HAVE_LLVM >= 0x1000
+         const clang::InputKind ik_opencl = clang::Language::OpenCL;
+#elif HAVE_LLVM >= 0x0900
+         const clang::InputKind ik_opencl = clang::InputKind::Language::OpenCL;
+#elif HAVE_LLVM >= 0x0500
          const clang::InputKind ik_opencl = clang::InputKind::OpenCL;
-         const clang::LangStandard::Kind lang_opencl10 = clang::LangStandard::lang_opencl10;
 #else
          const clang::InputKind ik_opencl = clang::IK_OpenCL;
+#endif
+
+#if HAVE_LLVM >= 0x0500
+         const clang::LangStandard::Kind lang_opencl10 = clang::LangStandard::lang_opencl10;
+#else
          const clang::LangStandard::Kind lang_opencl10 = clang::LangStandard::lang_opencl;
 #endif