Loading src/TNL/Containers/Algorithms/ArrayOperations.h +1 −3 Original line number Diff line number Diff line Loading @@ -14,8 +14,6 @@ #include <TNL/Devices/Cuda.h> #include <TNL/Devices/MIC.h> #include <iostream> namespace TNL { namespace Containers { namespace Algorithms { Loading src/TNL/Containers/Algorithms/ArrayOperationsMIC_impl.h +6 −6 Original line number Diff line number Diff line Loading @@ -56,7 +56,7 @@ freeMemory( Element* data ) return true; #else MICSupportMissingMessage;; true; return false; #endif } Loading src/TNL/Containers/Array.h +0 −2 Original line number Diff line number Diff line Loading @@ -177,5 +177,3 @@ std::ostream& operator << ( std::ostream& str, const Array< Element, Device, Ind } // namespace TNL #include <TNL/Containers/Array_impl.h> src/TNL/Devices/CudaCallable.h +4 −5 Original line number Diff line number Diff line /*************************************************************************** * - description CudaCallable.h - description ------------------- begin : Jun 20, 2017 copyright : (C) 2017 by Tomas Oberhuber et al. Loading src/TNL/Math.h +7 −16 Original line number Diff line number Diff line Loading @@ -39,11 +39,10 @@ __cuda_callable__ inline typename enable_if_same_base< T, int >::type min( const T& a, const T& b ) { #ifdef __CUDA_ARCH__ #if defined(__CUDA_ARCH__) || defined(__MIC__) return ::min( a, b ); #else //return std::min( a, b ); return !(b<a)?a:b; return std::min( a, b ); #endif } Loading Loading @@ -92,15 +91,11 @@ __cuda_callable__ inline typename enable_if_same_base< T, int >::type max( const T& a, const T& b ) { #ifdef __CUDA_ARCH__ #else #ifdef __MIC__ #if defined(__CUDA_ARCH__) || defined(__MIC__) return ::max( a, b ); #else return std::max( a, b ); #endif #endif } // specialization for float Loading Loading @@ -151,14 +146,10 @@ __cuda_callable__ inline typename std::enable_if< std::is_arithmetic< T >::value, T >::type abs( const T& n ) { #ifdef __CUDA_ARCH__ #if defined(__CUDA_ARCH__) || defined(__MIC__) return ::abs( n ); #else /*return std::abs( n );*/ if(n>=0) return n; else return -n; return std::abs( n ); #endif } Loading Loading
src/TNL/Containers/Algorithms/ArrayOperations.h +1 −3 Original line number Diff line number Diff line Loading @@ -14,8 +14,6 @@ #include <TNL/Devices/Cuda.h> #include <TNL/Devices/MIC.h> #include <iostream> namespace TNL { namespace Containers { namespace Algorithms { Loading
src/TNL/Containers/Algorithms/ArrayOperationsMIC_impl.h +6 −6 Original line number Diff line number Diff line Loading @@ -56,7 +56,7 @@ freeMemory( Element* data ) return true; #else MICSupportMissingMessage;; true; return false; #endif } Loading
src/TNL/Containers/Array.h +0 −2 Original line number Diff line number Diff line Loading @@ -177,5 +177,3 @@ std::ostream& operator << ( std::ostream& str, const Array< Element, Device, Ind } // namespace TNL #include <TNL/Containers/Array_impl.h>
src/TNL/Devices/CudaCallable.h +4 −5 Original line number Diff line number Diff line /*************************************************************************** * - description CudaCallable.h - description ------------------- begin : Jun 20, 2017 copyright : (C) 2017 by Tomas Oberhuber et al. Loading
src/TNL/Math.h +7 −16 Original line number Diff line number Diff line Loading @@ -39,11 +39,10 @@ __cuda_callable__ inline typename enable_if_same_base< T, int >::type min( const T& a, const T& b ) { #ifdef __CUDA_ARCH__ #if defined(__CUDA_ARCH__) || defined(__MIC__) return ::min( a, b ); #else //return std::min( a, b ); return !(b<a)?a:b; return std::min( a, b ); #endif } Loading Loading @@ -92,15 +91,11 @@ __cuda_callable__ inline typename enable_if_same_base< T, int >::type max( const T& a, const T& b ) { #ifdef __CUDA_ARCH__ #else #ifdef __MIC__ #if defined(__CUDA_ARCH__) || defined(__MIC__) return ::max( a, b ); #else return std::max( a, b ); #endif #endif } // specialization for float Loading Loading @@ -151,14 +146,10 @@ __cuda_callable__ inline typename std::enable_if< std::is_arithmetic< T >::value, T >::type abs( const T& n ) { #ifdef __CUDA_ARCH__ #if defined(__CUDA_ARCH__) || defined(__MIC__) return ::abs( n ); #else /*return std::abs( n );*/ if(n>=0) return n; else return -n; return std::abs( n ); #endif } Loading