From 5ba0ebe7c93513d11d21bb80d0db0a0390bb6300 Mon Sep 17 00:00:00 2001 From: Benoit Steiner Date: Mon, 23 May 2016 17:14:31 -0700 Subject: [PATCH] Avoid unnecessary float to double conversion. --- Eigen/src/Core/arch/CUDA/MathFunctions.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Eigen/src/Core/arch/CUDA/MathFunctions.h b/Eigen/src/Core/arch/CUDA/MathFunctions.h index 317499b29..c90ec96a0 100644 --- a/Eigen/src/Core/arch/CUDA/MathFunctions.h +++ b/Eigen/src/Core/arch/CUDA/MathFunctions.h @@ -123,7 +123,7 @@ double2 ppolygamma(const double2& n, const double2& x) template<> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE float4 perf(const float4& a) { - return make_float4(erf(a.x), erf(a.y), erf(a.z), erf(a.w)); + return make_float4(erff(a.x), erff(a.y), erff(a.z), erff(a.w)); } template<> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE @@ -135,7 +135,7 @@ double2 perf(const double2& a) template<> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE float4 perfc(const float4& a) { - return make_float4(erfc(a.x), erfc(a.y), erfc(a.z), erfc(a.w)); + return make_float4(erfcf(a.x), erfcf(a.y), erfcf(a.z), erfcf(a.w)); } template<> EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE