Author: jvesely Date: Fri Nov 10 14:16:36 2017 New Revision: 317939 URL: http://llvm.org/viewvc/llvm-project?rev=317939&view=rev Log: native_sin: Switch implementation to llvm intrinsic
Reviewer: Jeroen Ketema Signed-off-by: Jan Vesely <jan.ves...@rutgers.edu> Added: libclc/trunk/generic/lib/math/native_sin.cl Modified: libclc/trunk/generic/include/clc/math/native_sin.h libclc/trunk/generic/lib/SOURCES Modified: libclc/trunk/generic/include/clc/math/native_sin.h URL: http://llvm.org/viewvc/llvm-project/libclc/trunk/generic/include/clc/math/native_sin.h?rev=317939&r1=317938&r2=317939&view=diff ============================================================================== --- libclc/trunk/generic/include/clc/math/native_sin.h (original) +++ libclc/trunk/generic/include/clc/math/native_sin.h Fri Nov 10 14:16:36 2017 @@ -1 +1,9 @@ -#define native_sin sin +#define __CLC_BODY <clc/math/unary_decl.inc> +#define __CLC_FUNCTION native_sin +#define __FLOAT_ONLY + +#include <clc/math/gentype.inc> + +#undef __FLOAT_ONLY +#undef __CLC_BODY +#undef __CLC_FUNCTION Modified: libclc/trunk/generic/lib/SOURCES URL: http://llvm.org/viewvc/llvm-project/libclc/trunk/generic/lib/SOURCES?rev=317939&r1=317938&r2=317939&view=diff ============================================================================== --- libclc/trunk/generic/lib/SOURCES (original) +++ libclc/trunk/generic/lib/SOURCES Fri Nov 10 14:16:36 2017 @@ -125,6 +125,7 @@ math/native_exp2.cl math/native_log.cl math/native_log10.cl math/native_log2.cl +math/native_sin.cl math/tables.cl math/clc_nextafter.cl math/nextafter.cl Added: libclc/trunk/generic/lib/math/native_sin.cl URL: http://llvm.org/viewvc/llvm-project/libclc/trunk/generic/lib/math/native_sin.cl?rev=317939&view=auto ============================================================================== --- libclc/trunk/generic/lib/math/native_sin.cl (added) +++ libclc/trunk/generic/lib/math/native_sin.cl Fri Nov 10 14:16:36 2017 @@ -0,0 +1,7 @@ +#include <clc/clc.h> + +#define __CLC_NATIVE_INTRINSIC sin + +#define __CLC_BODY <native_unary_intrinsic.inc> +#define __FLOAT_ONLY +#include <clc/math/gentype.inc> _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits