10 #ifndef EIGEN_MATH_FUNCTIONS_GPU_H
11 #define EIGEN_MATH_FUNCTIONS_GPU_H
13 #include "../../InternalHeaderCheck.h"
22 #if defined(EIGEN_GPUCC) && defined(EIGEN_USE_GPU)
24 float4 plog<float4>(
const float4&
a)
26 return make_float4(logf(
a.x), logf(
a.y), logf(
a.z), logf(
a.w));
30 double2 plog<double2>(
const double2&
a)
33 return make_double2(
log(
a.x),
log(
a.y));
37 float4 plog1p<float4>(
const float4&
a)
39 return make_float4(log1pf(
a.x), log1pf(
a.y), log1pf(
a.z), log1pf(
a.w));
43 double2 plog1p<double2>(
const double2&
a)
49 float4 pexp<float4>(
const float4&
a)
51 return make_float4(expf(
a.x), expf(
a.y), expf(
a.z), expf(
a.w));
55 double2 pexp<double2>(
const double2&
a)
58 return make_double2(
exp(
a.x),
exp(
a.y));
62 float4 pexpm1<float4>(
const float4&
a)
64 return make_float4(expm1f(
a.x), expm1f(
a.y), expm1f(
a.z), expm1f(
a.w));
68 double2 pexpm1<double2>(
const double2&
a)
74 float4 psqrt<float4>(
const float4&
a)
76 return make_float4(sqrtf(
a.x), sqrtf(
a.y), sqrtf(
a.z), sqrtf(
a.w));
80 double2 psqrt<double2>(
const double2&
a)
87 float4 prsqrt<float4>(
const float4&
a)
89 return make_float4(rsqrtf(
a.x), rsqrtf(
a.y), rsqrtf(
a.z), rsqrtf(
a.w));
93 double2 prsqrt<double2>(
const double2&
a)
const ExpReturnType exp() const
const SqrtReturnType sqrt() const
const LogReturnType log() const
#define EIGEN_DEVICE_FUNC
const Eigen::CwiseUnaryOp< Eigen::internal::scalar_rsqrt_op< typename Derived::Scalar >, const Derived > rsqrt(const Eigen::ArrayBase< Derived > &x)
const Eigen::CwiseUnaryOp< Eigen::internal::scalar_log1p_op< typename Derived::Scalar >, const Derived > log1p(const Eigen::ArrayBase< Derived > &x)
const Eigen::CwiseUnaryOp< Eigen::internal::scalar_exp_op< typename Derived::Scalar >, const Derived > exp(const Eigen::ArrayBase< Derived > &x)
const Eigen::CwiseUnaryOp< Eigen::internal::scalar_expm1_op< typename Derived::Scalar >, const Derived > expm1(const Eigen::ArrayBase< Derived > &x)
const Eigen::CwiseUnaryOp< Eigen::internal::scalar_log_op< typename Derived::Scalar >, const Derived > log(const Eigen::ArrayBase< Derived > &x)
const Eigen::CwiseUnaryOp< Eigen::internal::scalar_sqrt_op< typename Derived::Scalar >, const Derived > sqrt(const Eigen::ArrayBase< Derived > &x)