diff options
| author | Jan Vesely <jan.vesely@rutgers.edu> | 2017-10-25 16:49:22 +0000 |
|---|---|---|
| committer | Jan Vesely <jan.vesely@rutgers.edu> | 2017-10-25 16:49:22 +0000 |
| commit | 47e093da9b48260e6f030fc21a96ef03b4a1fec5 (patch) | |
| tree | 9b8410be2a7a2f25bbb121050916679947b70a69 /libclc/generic/include | |
| parent | 9fedbb9d8e0c43cead1dbb5ae5877ee02a18ea3d (diff) | |
| download | bcm5719-llvm-47e093da9b48260e6f030fc21a96ef03b4a1fec5.tar.gz bcm5719-llvm-47e093da9b48260e6f030fc21a96ef03b4a1fec5.zip | |
math: Implement native_log10
Use llvm instrinsic by default
Provide amdgpu workaround
v2: drop old amd copyrights
Reviewer: Aaron Watry
Reviewed-by: Vedran Miletić <vedran@miletic.net>
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
llvm-svn: 316588
Diffstat (limited to 'libclc/generic/include')
| -rw-r--r-- | libclc/generic/include/clc/clc.h | 1 | ||||
| -rw-r--r-- | libclc/generic/include/clc/math/native_log10.h | 5 | ||||
| -rw-r--r-- | libclc/generic/include/clc/math/native_log10.inc | 1 |
3 files changed, 7 insertions, 0 deletions
diff --git a/libclc/generic/include/clc/clc.h b/libclc/generic/include/clc/clc.h index 3701336ad1a..5d64751e365 100644 --- a/libclc/generic/include/clc/clc.h +++ b/libclc/generic/include/clc/clc.h @@ -104,6 +104,7 @@ #include <clc/math/native_exp10.h> #include <clc/math/native_exp2.h> #include <clc/math/native_log.h> +#include <clc/math/native_log10.h> #include <clc/math/native_log2.h> #include <clc/math/native_powr.h> #include <clc/math/native_recip.h> diff --git a/libclc/generic/include/clc/math/native_log10.h b/libclc/generic/include/clc/math/native_log10.h new file mode 100644 index 00000000000..b877efdfac4 --- /dev/null +++ b/libclc/generic/include/clc/math/native_log10.h @@ -0,0 +1,5 @@ +#define __CLC_BODY <clc/math/native_log10.inc> +#define __FLOAT_ONLY +#include <clc/math/gentype.inc> +#undef __CLC_BODY +#undef __FLOAT_ONLY diff --git a/libclc/generic/include/clc/math/native_log10.inc b/libclc/generic/include/clc/math/native_log10.inc new file mode 100644 index 00000000000..ce5a9949714 --- /dev/null +++ b/libclc/generic/include/clc/math/native_log10.inc @@ -0,0 +1 @@ +_CLC_OVERLOAD _CLC_DECL __CLC_GENTYPE native_log10(__CLC_GENTYPE a); |

