Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
Diffstat (limited to 'intern')
-rw-r--r--intern/cycles/kernel/kernel_compat_opencl.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/intern/cycles/kernel/kernel_compat_opencl.h b/intern/cycles/kernel/kernel_compat_opencl.h
index 35dc95ca10d..ba7ab43a47a 100644
--- a/intern/cycles/kernel/kernel_compat_opencl.h
+++ b/intern/cycles/kernel/kernel_compat_opencl.h
@@ -43,12 +43,17 @@
#define ccl_local __local
#define ccl_local_param __local
#define ccl_private __private
-#define ccl_loop_no_unroll __attribute__((opencl_unroll_hint(1)))
#define ccl_restrict restrict
#define ccl_ref
#define ccl_align(n) __attribute__((aligned(n)))
#define ccl_optional_struct_init
+#if __OPENCL_VERSION__ >= 200
+# define ccl_loop_no_unroll __attribute__((opencl_unroll_hint(1)))
+#else
+# define ccl_loop_no_unroll
+#endif
+
#ifdef __SPLIT_KERNEL__
# define ccl_addr_space __global
#else