From 868ded6d87ca4e05482d2ae6955ddfbe0fb85ff0 Mon Sep 17 00:00:00 2001 From: Lorn Potter Date: Thu, 12 Dec 2019 09:38:20 +1000 Subject: wasm: do not use clamp mode for upstream LLVM MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Emscripten version 1.39.0 and above are based upon upstream LLVM, which does not contain BINARYEN_TRAP_MODE Fixes: QTBUG-80691 Change-Id: I6129f84a31a607c202e13847b50705ef1c809630 Reviewed-by: jian liang Reviewed-by: Morten Johan Sørvig --- mkspecs/features/wasm/default_pre.prf | 25 +------------------------ mkspecs/features/wasm/emcc_ver.prf | 23 +++++++++++++++++++++++ mkspecs/wasm-emscripten/qmake.conf | 6 +++++- 3 files changed, 29 insertions(+), 25 deletions(-) create mode 100644 mkspecs/features/wasm/emcc_ver.prf (limited to 'mkspecs') diff --git a/mkspecs/features/wasm/default_pre.prf b/mkspecs/features/wasm/default_pre.prf index 982ef0498f..2760889929 100644 --- a/mkspecs/features/wasm/default_pre.prf +++ b/mkspecs/features/wasm/default_pre.prf @@ -1,25 +1,2 @@ load(default_pre) - -defineReplace(qtEmccRecommendedVersion) { - return (1.38.27) -} - -defineReplace(qtSystemEmccVersion) { - E_VERSION = $$system("emcc -v 2>&1 | perl -alne $$shell_quote($_ = $F[9]; s/://; print;) ") - return ($${E_VERSION}) -} - -defineTest(qtConfTest_emccVersion) { - - REQ_VERSION = $$qtEmccRecommendedVersion() - EMCC_VERSION = $$qtSystemEmccVersion() - - !defined(QT_EMCC_VERSION, var):!equals(EMCC_VERSION, $${REQ_VERSION}) { - warning ("You should use the recommended Emscripten version $$REQ_VERSION with this Qt. You have $${EMCC_VERSION} ") - } - contains(TEMPLATE, .*app) { - !equals(QT_EMCC_VERSION, $$EMCC_VERSION) { - warning("This Qt was built with Emscripten version $${QT_EMCC_VERSION}. You have $${EMCC_VERSION}. The difference may cause issues.") - } - } -} +load(emcc_ver) diff --git a/mkspecs/features/wasm/emcc_ver.prf b/mkspecs/features/wasm/emcc_ver.prf new file mode 100644 index 0000000000..505a321d64 --- /dev/null +++ b/mkspecs/features/wasm/emcc_ver.prf @@ -0,0 +1,23 @@ +defineReplace(qtEmccRecommendedVersion) { + return (1.38.27) +} + +defineReplace(qtSystemEmccVersion) { + E_VERSION = $$system("emcc -v 2>&1 | perl -alne $$shell_quote($_ = $F[9]; s/://; print;) ") + return ($${E_VERSION}) +} + +defineTest(qtConfTest_emccVersion) { + + REQ_VERSION = $$qtEmccRecommendedVersion() + EMCC_VERSION = $$qtSystemEmccVersion() + + !defined(QT_EMCC_VERSION, var):!equals(EMCC_VERSION, $${REQ_VERSION}) { + warning ("You should use the recommended Emscripten version $$REQ_VERSION with this Qt. You have $${EMCC_VERSION} ") + } + contains(TEMPLATE, .*app) { + !equals(QT_EMCC_VERSION, $$EMCC_VERSION) { + warning("This Qt was built with Emscripten version $${QT_EMCC_VERSION}. You have $${EMCC_VERSION}. The difference may cause issues.") + } + } +} diff --git a/mkspecs/wasm-emscripten/qmake.conf b/mkspecs/wasm-emscripten/qmake.conf index cde6dac42b..48c3fb7359 100644 --- a/mkspecs/wasm-emscripten/qmake.conf +++ b/mkspecs/wasm-emscripten/qmake.conf @@ -6,6 +6,7 @@ include(../common/gcc-base.conf) include(../common/clang.conf) load(device_config) +load(emcc_ver) # Support setting WASM_OBJECT_FILES with -device-option WASM_OBJECT_FILES=1 !isEmpty(WASM_OBJECT_FILES): { @@ -15,7 +16,10 @@ load(device_config) QMAKE_CXXFLAGS += -s WASM_OBJECT_FILES=$$WASM_OBJECT_FILES QMAKE_LFLAGS += -s WASM_OBJECT_FILES=$$WASM_OBJECT_FILES } else { - EMCC_COMMON_LFLAGS += -s \"BINARYEN_TRAP_MODE=\'clamp\'\" + EMSCRIPTEN_VERSION=$$qtSystemEmccVersion() + lessThan(EMSCRIPTEN_VERSION, 1.39) { + EMCC_COMMON_LFLAGS += -s \"BINARYEN_TRAP_MODE=\'clamp\'\" + } } EMTERP_FLAGS = \ -- cgit v1.2.3 From 669a29f5e7f18d021927b9dd56b2fcb1c644baf6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Wed, 18 Dec 2019 00:39:56 +0100 Subject: Xcode: Disable GPU frame capture and Metal API validation by default The auto-detection Xcode has for whether GPU capture should be enabled always enables it for our projects, which adds up to second to the startup time when debugging. There's no need to pay this cost unless you're actively debugging Metal code. Change-Id: I4a76c4e7afedad4bb43395ae64bc0f8d62eca6be Reviewed-by: Eirik Aavitsland --- mkspecs/macx-xcode/default.xcscheme | 2 ++ 1 file changed, 2 insertions(+) (limited to 'mkspecs') diff --git a/mkspecs/macx-xcode/default.xcscheme b/mkspecs/macx-xcode/default.xcscheme index 170174ed2b..355765e964 100644 --- a/mkspecs/macx-xcode/default.xcscheme +++ b/mkspecs/macx-xcode/default.xcscheme @@ -64,6 +64,8 @@ buildConfiguration = "Debug" ignoresPersistentStateOnLaunch = "NO" disableMainThreadChecker = "YES" + enableGPUFrameCaptureMode = "3" + enableGPUValidationMode = "1" debugDocumentVersioning = "NO" allowLocationSimulation = "YES"> -- cgit v1.2.3 From fe784abc80a2e322a98a5100f6debe4ed8b0e17d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Fri, 20 Dec 2019 12:10:18 +0100 Subject: iOS: Silence GL deprecations until we can fix them Change-Id: I1222708be5017a0dca381f365349fce5887a0bcb Reviewed-by: Timur Pocheptsov --- mkspecs/common/uikit.conf | 2 ++ 1 file changed, 2 insertions(+) (limited to 'mkspecs') diff --git a/mkspecs/common/uikit.conf b/mkspecs/common/uikit.conf index 0388b8e616..424381e285 100644 --- a/mkspecs/common/uikit.conf +++ b/mkspecs/common/uikit.conf @@ -7,4 +7,6 @@ CONFIG += bitcode reduce_exports shallow_bundle no_qt_rpath INCLUDEPATH += $$PWD/uikit +DEFINES += GLES_SILENCE_DEPRECATION + include(mac.conf) -- cgit v1.2.3