authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2020-12-04 15:39:16-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2020-12-04 15:39:16-07:00
log1c5606af9fdbfa18fb312a35a73c68515967c94d
treec095c53b6e11b6895934b791d24a4fefce3ffb69
parentfd8fa551295cdf8eac2f524bda835dce731a4c0a

update to latest clang C headers


3 files changed, 7 insertions(+), 3 deletions(-)

lib/include/__clang_cuda_complex_builtins.h+3-3
......@@ -16,7 +16,7 @@
1616// to work with CUDA and OpenMP target offloading [in C and C++ mode].)
1717
1818#pragma push_macro("__DEVICE__")
19#ifdef _OPENMP
19#ifdef __OPENMP_NVPTX__
2020#pragma omp declare target
2121#define __DEVICE__ __attribute__((noinline, nothrow, cold, weak))
2222#else
......@@ -26,7 +26,7 @@
2626// To make the algorithms available for C and C++ in CUDA and OpenMP we select
2727// different but equivalent function versions. TODO: For OpenMP we currently
2828// select the native builtins as the overload support for templates is lacking.
29#if !defined(_OPENMP)
29#if !defined(__OPENMP_NVPTX__)
3030#define _ISNANd std::isnan
3131#define _ISNANf std::isnan
3232#define _ISINFd std::isinf
......@@ -250,7 +250,7 @@ __DEVICE__ float _Complex __divsc3(float __a, float __b, float __c, float __d) {
250250#undef _LOGBd
251251#undef _LOGBf
252252
253#ifdef _OPENMP
253#ifdef __OPENMP_NVPTX__
254254#pragma omp end declare target
255255#endif
256256
lib/include/openmp_wrappers/complex+2
......@@ -18,7 +18,9 @@
1818#include <cmath>
1919
2020#define __CUDA__
21#define __OPENMP_NVPTX__
2122#include <__clang_cuda_complex_builtins.h>
23#undef __OPENMP_NVPTX__
2224#endif
2325
2426// Grab the host header too.
lib/include/openmp_wrappers/complex.h+2
......@@ -18,7 +18,9 @@
1818#include <math.h>
1919
2020#define __CUDA__
21#define __OPENMP_NVPTX__
2122#include <__clang_cuda_complex_builtins.h>
23#undef __OPENMP_NVPTX__
2224#endif
2325
2426// Grab the host header too.