Cycles: Remove fermi related defines from the code.
authorThomas Dinges <blender@dingto.org>
Sat, 17 Feb 2018 21:19:54 +0000 (22:19 +0100)
committerThomas Dinges <blender@dingto.org>
Sat, 17 Feb 2018 21:19:54 +0000 (22:19 +0100)
Did not touch Texture related defines, that comes next.

intern/cycles/kernel/geom/geom_curve_intersect.h
intern/cycles/kernel/kernel_compat_cuda.h
intern/cycles/kernel/kernels/cuda/kernel_config.h
intern/cycles/util/util_math_intersect.h

index e9a149ea1ab95debeb6c7591bb72bae91075b481..7f24aea5d28f69c03690959cd7d0003e9e89ebf8 100644 (file)
@@ -18,12 +18,6 @@ CCL_NAMESPACE_BEGIN
 
 #ifdef __HAIR__
 
-#if defined(__KERNEL_CUDA__) && (__CUDA_ARCH__ < 300)
-#  define ccl_device_curveintersect ccl_device
-#else
-#  define ccl_device_curveintersect ccl_device_forceinline
-#endif
-
 #ifdef __KERNEL_SSE2__
 ccl_device_inline ssef transform_point_T3(const ssef t[3], const ssef &a)
 {
@@ -32,7 +26,7 @@ ccl_device_inline ssef transform_point_T3(const ssef t[3], const ssef &a)
 #endif
 
 /* On CPU pass P and dir by reference to aligned vector. */
-ccl_device_curveintersect bool cardinal_curve_intersect(
+ccl_device_forceinline bool cardinal_curve_intersect(
         KernelGlobals *kg,
         Intersection *isect,
         const float3 ccl_ref P,
@@ -505,7 +499,7 @@ ccl_device_curveintersect bool cardinal_curve_intersect(
        return hit;
 }
 
-ccl_device_curveintersect bool curve_intersect(KernelGlobals *kg,
+ccl_device_forceinline bool curve_intersect(KernelGlobals *kg,
                                                Intersection *isect,
                                                float3 P,
                                                float3 direction,
index 900f7fe6a2c991fc7af6abe418004b19b3c76cd4..1daa7f0db16cc6f53c991562b4194fa94b825665 100644 (file)
@@ -50,10 +50,7 @@ __device__ half __float2half(const float f)
 /* Qualifier wrappers for different names on different devices */
 
 #define ccl_device  __device__ __inline__
-#if __CUDA_ARCH__ < 300
-#  define ccl_device_inline  __device__ __inline__
-#  define ccl_device_forceinline  __device__ __forceinline__
-#elif __CUDA_ARCH__ < 500
+#if __CUDA_ARCH__ < 500
 #  define ccl_device_inline  __device__ __forceinline__
 #  define ccl_device_forceinline  __device__ __forceinline__
 #else
index 94f59ff38d9cab05680b4cd4e88193d21340d61f..f3d0d721c5cebe5f021fbda4aacd1568f39409c2 100644 (file)
 
 /* device data taken from CUDA occupancy calculator */
 
-/* 2.0 and 2.1 */
-#if __CUDA_ARCH__ == 200 || __CUDA_ARCH__ == 210
-#  define CUDA_MULTIPRESSOR_MAX_REGISTERS 32768
-#  define CUDA_MULTIPROCESSOR_MAX_BLOCKS 8
-#  define CUDA_BLOCK_MAX_THREADS 1024
-#  define CUDA_THREAD_MAX_REGISTERS 63
-
-/* tunable parameters */
-#  define CUDA_THREADS_BLOCK_WIDTH 16
-#  define CUDA_KERNEL_MAX_REGISTERS 32
-#  define CUDA_KERNEL_BRANCHED_MAX_REGISTERS 40
-
 /* 3.0 and 3.5 */
-#elif __CUDA_ARCH__ == 300 || __CUDA_ARCH__ == 350
+#if __CUDA_ARCH__ == 300 || __CUDA_ARCH__ == 350
 #  define CUDA_MULTIPRESSOR_MAX_REGISTERS 65536
 #  define CUDA_MULTIPROCESSOR_MAX_BLOCKS 16
 #  define CUDA_BLOCK_MAX_THREADS 1024
index 498c21b9706cc6da04b919e4bbd3a2a0e9dfb0d8..61ddcc38f506a67dd2f248cc3bae1b20428521b6 100644 (file)
@@ -79,12 +79,7 @@ ccl_device bool ray_aligned_disk_intersect(
        return true;
 }
 
-#if defined(__KERNEL_CUDA__) && __CUDA_ARCH__ < 300
-ccl_device_inline
-#else
-ccl_device_forceinline
-#endif
-bool ray_triangle_intersect(
+ccl_device_forceinline bool ray_triangle_intersect(
         float3 ray_P, float3 ray_dir, float ray_t,
 #if defined(__KERNEL_SSE2__) && defined(__KERNEL_SSE__)
         const ssef *ssef_verts,