[Bf-blender-cvs] [89ee6e0] master: Cycles: attempt to solve compilation error on 32bit OSX

Sergey Sharybin noreply at git.blender.org
Thu Jun 19 08:24:27 CEST 2014


Commit: 89ee6e08087dedd543da569a2ae0a4d64c43f368
Author: Sergey Sharybin
Date:   Thu Jun 19 12:24:08 2014 +0600
https://developer.blender.org/rB89ee6e08087dedd543da569a2ae0a4d64c43f368

Cycles: attempt to solve compilation error on 32bit OSX

===================================================================

M	intern/cycles/util/util_simd.h

===================================================================

diff --git a/intern/cycles/util/util_simd.h b/intern/cycles/util/util_simd.h
index 9b86e8b..39506a6 100644
--- a/intern/cycles/util/util_simd.h
+++ b/intern/cycles/util/util_simd.h
@@ -225,7 +225,7 @@ __forceinline int __btr(int v, int i) {
   int r = 0; asm ("btr %1,%0" : "=r"(r) : "r"(i), "0"(v) : "flags"); return r;
 }
 
-#if defined(__KERNEL_64_BIT__)
+#if defined(__KERNEL_64_BIT__) || defined(__APPLE__)
 __forceinline size_t __bsf(size_t v) {
   size_t r = 0; asm ("bsf %1,%0" : "=r"(r) : "r"(v)); return r;
 }
@@ -267,7 +267,7 @@ __forceinline unsigned int bitscan(unsigned int v) {
 #endif
 }
 
-#if defined(__KERNEL_64_BIT__)
+#if defined(__KERNEL_64_BIT__) || defined(__APPLE__)
 __forceinline size_t bitscan(size_t v) {
 #if defined(__KERNEL_AVX2__)
 #if defined(__KERNEL_64_BIT__)
@@ -309,7 +309,7 @@ __forceinline unsigned int __bscf(unsigned int& v)
   return i;
 }
 
-#if defined(__KERNEL_64_BIT__)
+#if defined(__KERNEL_64_BIT__) || defined(__APPLE__)
 __forceinline size_t __bscf(size_t& v) 
 {
   size_t i = bitscan(v);




More information about the Bf-blender-cvs mailing list