summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorTom Stellard <[email protected]>2014-02-25 13:32:37 -0800
committerTom Stellard <[email protected]>2014-02-25 14:43:26 -0800
commit54df6a049110464c4ba2ad97b12b69ede927eca4 (patch)
tree9181678a84af6b6be23c34feec13552ab459ea3e /src/gallium
parentf094866d93b772cc91844e012ad07ce4a78fda5d (diff)
Re-commit 'clover: Fix build with LLVM 3.5'
This was accidentally reverted in 9dfd7c5f75c806801b1b4b4d405899236c09ba75
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/state_trackers/clover/llvm/invocation.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/clover/llvm/invocation.cpp b/src/gallium/state_trackers/clover/llvm/invocation.cpp
index e8266693bd0..cdf32b6e3fb 100644
--- a/src/gallium/state_trackers/clover/llvm/invocation.cpp
+++ b/src/gallium/state_trackers/clover/llvm/invocation.cpp
@@ -297,8 +297,10 @@ namespace {
llvm::Argument &arg = *I;
#if HAVE_LLVM < 0x0302
llvm::TargetData TD(kernel_func->getParent());
-#else
+#elif HAVE_LLVM < 0x0304
llvm::DataLayout TD(kernel_func->getParent()->getDataLayout());
+#else
+ llvm::DataLayout TD(mod);
#endif
llvm::Type *arg_type = arg.getType();