[libclc] 39/79: math.h: Set HAVE_HW_FMA32 based on compiler provided macro
Andreas Boll
aboll-guest at moszumanska.debian.org
Mon Mar 19 16:50:58 UTC 2018
This is an automated email from the git hooks/post-receive script.
aboll-guest pushed a commit to branch master
in repository libclc.
commit e7fc75dcfb26ef614f72fac0c9077122c8488fd5
Author: Jan Vesely <jan.vesely at rutgers.edu>
Date: Mon Jan 29 19:05:08 2018 +0000
math.h: Set HAVE_HW_FMA32 based on compiler provided macro
Fixes sin/cos piglits on non-FMA capable asics.
Bugzilla: https://bugs.llvm.org/show_bug.cgi?id=35983
Reviewer: Tom Stellard
Signed-off-by: Jan Vesely <jan.vesely at rutgers.edu>
git-svn-id: https://llvm.org/svn/llvm-project/libclc/trunk@323677 91177308-0d34-0410-b5e6-96231b3b80d8
---
generic/lib/math/math.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/generic/lib/math/math.h b/generic/lib/math/math.h
index f46c7ea..0a10991 100644
--- a/generic/lib/math/math.h
+++ b/generic/lib/math/math.h
@@ -31,7 +31,12 @@
#define PNOR 0x100
#define PINF 0x200
+#if (defined __AMDGCN__ | defined __R600__) & !defined __HAS_FMAF__
+#define HAVE_HW_FMA32() (0)
+#else
#define HAVE_HW_FMA32() (1)
+#endif
+
#define HAVE_BITALIGN() (0)
#define HAVE_FAST_FMA32() (0)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-opencl/libclc.git
More information about the Pkg-opencl-commits
mailing list