diff options
Diffstat (limited to 'backend/src/libocl/tmpl')
-rw-r--r-- | backend/src/libocl/tmpl/ocl_math_common.tmpl.cl | 5 | ||||
-rw-r--r-- | backend/src/libocl/tmpl/ocl_math_common.tmpl.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/backend/src/libocl/tmpl/ocl_math_common.tmpl.cl b/backend/src/libocl/tmpl/ocl_math_common.tmpl.cl index c370864a..e6452388 100644 --- a/backend/src/libocl/tmpl/ocl_math_common.tmpl.cl +++ b/backend/src/libocl/tmpl/ocl_math_common.tmpl.cl @@ -1089,6 +1089,11 @@ OVERLOADABLE double cosh(double x) } +OVERLOADABLE double cospi(double x) +{ + return cos(x*M_PI); +} + OVERLOADABLE double fabs(double x) { long qw = as_ulong(x); diff --git a/backend/src/libocl/tmpl/ocl_math_common.tmpl.h b/backend/src/libocl/tmpl/ocl_math_common.tmpl.h index 471f8664..5f703f38 100644 --- a/backend/src/libocl/tmpl/ocl_math_common.tmpl.h +++ b/backend/src/libocl/tmpl/ocl_math_common.tmpl.h @@ -37,6 +37,7 @@ OVERLOADABLE double ceil(double x); OVERLOADABLE double copysign(double x, double y); OVERLOADABLE double cos(double x); OVERLOADABLE double cosh(double x); +OVERLOADABLE double cospi(double x); OVERLOADABLE double fabs(double x); OVERLOADABLE double fdim(double x, double y); OVERLOADABLE double floor(double x); |