From 2ef5ec6b2bc0c0bcc5b7b09004de4038fe1f901e Mon Sep 17 00:00:00 2001 From: Tom Stellard Date: Fri, 10 Jul 2015 13:37:07 +0000 Subject: Fix implementation of sqrt v2 Passing values less than 0 to the llvm.sqrt() intrinsic results in undefined behavior, so we need to check the input and return NaN if is is less than 0. v2: - Fix build failures. llvm-svn: 241906 --- libclc/generic/lib/SOURCES | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libclc/generic/lib/SOURCES') diff --git a/libclc/generic/lib/SOURCES b/libclc/generic/lib/SOURCES index 1e639948374..565404bd480 100644 --- a/libclc/generic/lib/SOURCES +++ b/libclc/generic/lib/SOURCES @@ -102,6 +102,8 @@ math/sin.cl math/sincos.cl math/sincos_helpers.cl math/sinpi.cl +math/clc_sqrt.cl +math/sqrt.cl math/tan.cl relational/all.cl relational/any.cl -- cgit v1.2.3