summaryrefslogtreecommitdiffstats
path: root/src/corelib/global/qfloat16_f16c.c
diff options
context:
space:
mode:
authorTarja Sundqvist <tarja.sundqvist@qt.io>2022-11-11 09:29:17 +0200
committerTarja Sundqvist <tarja.sundqvist@qt.io>2022-11-11 09:29:17 +0200
commit4ee4fc18b4067b90efa46ca9baba74f53b54d9ec (patch)
treecc68622c9b85992d99a8373ab55471ee821a4ebf /src/corelib/global/qfloat16_f16c.c
parentab28ff2207e8f33754c79793089dbf943d67736d (diff)
parentebb49c66aaf22ed55d62ff7bc3690fce00b7d8ba (diff)
Merge remote-tracking branch 'origin/tqtc/lts-5.15.8' into tqtc/lts-5.15-opensourcev5.15.8-lts-lgpl
Diffstat (limited to 'src/corelib/global/qfloat16_f16c.c')
-rw-r--r--src/corelib/global/qfloat16_f16c.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/corelib/global/qfloat16_f16c.c b/src/corelib/global/qfloat16_f16c.c
index ba1e16f481..d60a021bdb 100644
--- a/src/corelib/global/qfloat16_f16c.c
+++ b/src/corelib/global/qfloat16_f16c.c
@@ -40,13 +40,8 @@
#include "private/qsimd_p.h"
// The x86 F16C instructions operate on AVX registers, so AVX support is
-// required. We don't need to check for __F16C__ because we this file wouldn't
-// have been compiled if the support was missing in the first place, and not
-// all compilers define it. Technically, we didn't need to check for __AVX__
-// either.
-#if !QT_COMPILER_SUPPORTS_HERE(AVX)
-# error "AVX support required"
-#endif
+// required.
+#if QT_COMPILER_SUPPORTS_HERE(AVX)
#ifdef __cplusplus
QT_BEGIN_NAMESPACE
@@ -89,3 +84,5 @@ void qFloatFromFloat16_fast(float *out, const quint16 *in, qsizetype len) Q_DECL
} // extern "C"
QT_END_NAMESPACE
#endif
+
+#endif // QT_COMPILER_SUPPORTS_HERE(AVX)