diff options
| author | Thiago Macieira <thiago.macieira@intel.com> | 2022-02-23 12:02:27 -0800 |
|---|---|---|
| committer | Thiago Macieira <thiago.macieira@intel.com> | 2022-03-03 15:44:54 -0800 |
| commit | 8e56a7bc6b01142129f6e316410df6f384983391 (patch) | |
| tree | 506571e4cb5b77248ea26f4cc4c5e80cb8489620 /src/corelib/global/qsimd.cpp | |
| parent | e8d3cf0909f5ebbd81245d7bca6ed3dd77ddb92d (diff) | |
qsimd.cpp: don't disable SSE FP math
Lowering the architecture all the way to the i386 baseline without SSE2
was causing warnings about disabling SSE FP math. We don't need to go
that low for 32-bit.
Task-number: QTBUG-101198
Change-Id: Ibf4acec0f166495998f7fffd16d682d0f5beec11
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/corelib/global/qsimd.cpp')
| -rw-r--r-- | src/corelib/global/qsimd.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/corelib/global/qsimd.cpp b/src/corelib/global/qsimd.cpp index fea25a73d74..a10cb6f6fb0 100644 --- a/src/corelib/global/qsimd.cpp +++ b/src/corelib/global/qsimd.cpp @@ -200,19 +200,21 @@ static inline quint64 detectProcessorFeatures() #ifdef Q_PROCESSOR_X86_32 # define PICreg "%%ebx" -# define X86_BASELINE "i386" #else # define PICreg "%%rbx" -# define X86_BASELINE "x86-64" +#endif +#ifdef __SSE2_MATH__ +# define X86_BASELINE "no-sse3" +#else +# define X86_BASELINE "no-sse" #endif #if defined(Q_CC_GNU) // lower the target for functions in this file # undef QT_FUNCTION_TARGET_BASELINE -# define QT_FUNCTION_TARGET_BASELINE __attribute__((target("arch=" X86_BASELINE))) +# define QT_FUNCTION_TARGET_BASELINE __attribute__((target(X86_BASELINE))) # define QT_FUNCTION_TARGET_STRING_BASELINE_RDRND \ - "arch=" X86_BASELINE \ - "," QT_FUNCTION_TARGET_STRING_RDRND + X86_BASELINE "," QT_FUNCTION_TARGET_STRING_RDRND #endif static bool checkRdrndWorks() noexcept; |
