diff options
author | Assam Boudjelthia <assam.boudjelthia@qt.io> | 2020-09-08 17:47:28 +0300 |
---|---|---|
committer | Assam Boudjelthia <assam.boudjelthia@qt.io> | 2020-09-10 18:29:05 +0300 |
commit | ff1a44be33f4bc05d502a2ca49171e0408992f61 (patch) | |
tree | e0ddd0b3f8880eae0f2362b5c15730ca296b27f2 | |
parent | 54c37146b78812e286a495a4bfc39d97858d3f99 (diff) |
Android: don't use avx and avx2 when building for Android x86_64
The Android build for x86_64 fails with CMake. It should also fail with
qmake builds but the current multi-ABI build is testing the feature for
arm64-v8a only.
In [1], it's stated that AVX and AVX2 are not supported on x86_64 ABI.
[1] https://developer.android.com/ndk/guides/abis#86-64
Task-number: QTBUG-85982
Change-Id: I20c9366bdee2a13ca554ec67f5d0c041bd068b91
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
-rw-r--r-- | configure.cmake | 4 | ||||
-rw-r--r-- | configure.json | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/configure.cmake b/configure.cmake index a824ce467d..e6302b5816 100644 --- a/configure.cmake +++ b/configure.cmake @@ -676,7 +676,7 @@ qt_feature_definition("sse4_2" "QT_COMPILER_SUPPORTS_SSE4_2" VALUE "1") qt_feature_config("sse4_2" QMAKE_PRIVATE_CONFIG) qt_feature("avx" LABEL "AVX" - CONDITION QT_FEATURE_sse4_2 AND TEST_subarch_avx + CONDITION QT_FEATURE_sse4_2 AND TEST_subarch_avx AND (NOT ANDROID OR NOT TEST_architecture_arch STREQUAL x86_64) ) qt_feature_definition("avx" "QT_COMPILER_SUPPORTS_AVX" VALUE "1") qt_feature_config("avx" QMAKE_PRIVATE_CONFIG) @@ -688,7 +688,7 @@ qt_feature_definition("f16c" "QT_COMPILER_SUPPORTS_F16C" VALUE "1") qt_feature_config("f16c" QMAKE_PRIVATE_CONFIG) qt_feature("avx2" PRIVATE LABEL "AVX2" - CONDITION QT_FEATURE_avx AND TEST_subarch_avx2 + CONDITION QT_FEATURE_avx AND TEST_subarch_avx2 AND (NOT ANDROID OR NOT TEST_architecture_arch STREQUAL x86_64) ) qt_feature_definition("avx2" "QT_COMPILER_SUPPORTS_AVX2" VALUE "1") qt_feature_config("avx2" QMAKE_PRIVATE_CONFIG) diff --git a/configure.json b/configure.json index 507ffd20dd..a00a22c6da 100644 --- a/configure.json +++ b/configure.json @@ -1084,7 +1084,7 @@ }, "avx": { "label": "AVX", - "condition": "features.sse4_2 && tests.avx", + "condition": "features.sse4_2 && tests.avx && (!config.android || !arch.x86_64)", "output": [ "privateConfig", { "type": "define", "name": "QT_COMPILER_SUPPORTS_AVX", "value": 1 } @@ -1100,7 +1100,7 @@ }, "avx2": { "label": "AVX2", - "condition": "features.avx && tests.avx2", + "condition": "features.avx && tests.avx2 && (!config.android || !arch.x86_64)", "output": [ "privateConfig", "privateFeature", |