fixed build for old compute capabilities
authorVladislav Vinogradov <vlad.vinogradov@itseez.com>
Fri, 10 Aug 2012 06:03:35 +0000 (10:03 +0400)
committerVladislav Vinogradov <vlad.vinogradov@itseez.com>
Fri, 10 Aug 2012 06:03:35 +0000 (10:03 +0400)
modules/gpu/src/cuda/ccomponetns.cu
modules/gpu/src/opencv2/gpu/device/emulation.hpp

index 1f9dc11..c11031b 100644 (file)
@@ -474,7 +474,7 @@ namespace cv { namespace gpu { namespace device
                         }
                     }
                 }
-            } while (__syncthreads_or(changed));
+            } while (Emulation::sycthOr(changed));
         }
 
         __global__ void flatten(const DevMem2D edges, DevMem2Di comps)
index 0999495..e116c50 100644 (file)
@@ -53,7 +53,7 @@ namespace cv { namespace gpu { namespace device
 
         static __device__ __forceinline__ int sycthOr(int pred)
         {
-#if defined (__CUDA_ARCH__) && (__CUDA_ARCH__ < 120)
+#if defined (__CUDA_ARCH__) && (__CUDA_ARCH__ < 200)
                 // just campilation stab
                 return false;
 #else
@@ -119,7 +119,7 @@ namespace cv { namespace gpu { namespace device
             static __device__ __forceinline__ T atomicMin(T* address, T val)
             {
 #if defined (__CUDA_ARCH__) && (__CUDA_ARCH__ < 120)
-                T count = min(*address, val);
+                T count = ::min(*address, val);
                 do
                 {
                     *address = count;