We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 99282a3 + 7b5d7c7 commit 4d0786aCopy full SHA for 4d0786a
clang/lib/Headers/__clang_hip_cmath.h
@@ -626,6 +626,13 @@ _GLIBCXX_END_NAMESPACE_VERSION
626
627
// Define device-side math functions from <ymath.h> on MSVC.
628
#if defined(_MSC_VER)
629
+
630
+// Before VS2019, `<ymath.h>` is also included in `<limits>` and other headers.
631
+// But, from VS2019, it's only included in `<complex>`. Need to include
632
+// `<ymath.h>` here to ensure C functions declared there won't be markded as
633
+// `__host__` and `__device__` through `<complex>` wrapper.
634
+#include <ymath.h>
635
636
#if defined(__cplusplus)
637
extern "C" {
638
#endif // defined(__cplusplus)
0 commit comments