From 7d06b97363ba2db8b80c5fc6d491529e559b405b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Thu, 14 Aug 2025 18:19:37 +0300 Subject: [PATCH 1/6] Update feature matrix to highlight unconditionally required DedicatedWorkerGlobalScope.name parameter. --- tools/feature_matrix.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/tools/feature_matrix.py b/tools/feature_matrix.py index dfd3dbb295c11..540af567ec4a0 100644 --- a/tools/feature_matrix.py +++ b/tools/feature_matrix.py @@ -15,12 +15,14 @@ UNSUPPORTED = 0x7FFFFFFF -# Oldest support browser versions. These have been set somewhat -# arbitrarily for now. +# Oldest support browser versions. +# Emscripten unconditionally requires support for: +# - DedicatedWorkerGlobalScope.name parameter for multithreading support, which +# landed first in Chrome 70, Firefox 55 and Safari 12.2. # TODO(sbc): Design a of policy for managing these values. -OLDEST_SUPPORTED_CHROME = 55 # December 1, 2016 -OLDEST_SUPPORTED_FIREFOX = 50 # November 15, 2016 -OLDEST_SUPPORTED_SAFARI = 101000 # September 20, 2016 +OLDEST_SUPPORTED_CHROME = 70 # October 16, 2018 +OLDEST_SUPPORTED_FIREFOX = 55 # August 08, 2017 +OLDEST_SUPPORTED_SAFARI = 120200 # March 25, 2019 # 10.19.0 is the oldest version of node that we do any testing with. # Keep this in sync with the test-node-compat in .circleci/config.yml. OLDEST_SUPPORTED_NODE = 101900 From 252969855188d4e5ae32cc722dce35e7102c4d8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Thu, 14 Aug 2025 19:30:07 +0300 Subject: [PATCH 2/6] Update comments --- src/settings.js | 6 +++--- tools/feature_matrix.py | 10 ++++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/settings.js b/src/settings.js index c5d63adf9414e..6457e1c40f5b3 100644 --- a/src/settings.js +++ b/src/settings.js @@ -1870,7 +1870,7 @@ var AUTO_NATIVE_LIBRARIES = true; // for Firefox versions older than < majorVersion. // Firefox 79 was released on 2020-07-28. // MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. -// Minimum supported value is 50 which was released on 2016-11-15 (see +// Minimum supported value is 55 which was released on 2017-08-08 (see // feature_matrix.py) // [link] var MIN_FIREFOX_VERSION = 79; @@ -1885,7 +1885,7 @@ var MIN_FIREFOX_VERSION = 79; // older, i.e. iPhone 4s, iPad 2, iPad 3, iPad Mini 1, Pod Touch 5 and older, // see https://github.com/emscripten-core/emscripten/pull/7191. // MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. -// Minimum supported value is 101000 which was released in 2016-09 (see +// Minimum supported value is 120200 which was released on 2019-03-25 (see // feature_matrix.py). // [link] var MIN_SAFARI_VERSION = 150000; @@ -1896,7 +1896,7 @@ var MIN_SAFARI_VERSION = 150000; // numbers with Chrome. // Chrome 85 was released on 2020-08-25. // MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. -// Minimum supported value is 55, which was released on 2016-12-01 (see +// Minimum supported value is 70, which was released on 2018-10-16 (see // feature_matrix.py). // [link] var MIN_CHROME_VERSION = 85; diff --git a/tools/feature_matrix.py b/tools/feature_matrix.py index 540af567ec4a0..03fb0c92f45eb 100644 --- a/tools/feature_matrix.py +++ b/tools/feature_matrix.py @@ -19,10 +19,12 @@ # Emscripten unconditionally requires support for: # - DedicatedWorkerGlobalScope.name parameter for multithreading support, which # landed first in Chrome 70, Firefox 55 and Safari 12.2. -# TODO(sbc): Design a of policy for managing these values. -OLDEST_SUPPORTED_CHROME = 70 # October 16, 2018 -OLDEST_SUPPORTED_FIREFOX = 55 # August 08, 2017 -OLDEST_SUPPORTED_SAFARI = 120200 # March 25, 2019 + +# N.b. when modifying these values, update comments in src/settings.js on +# MIN_x_VERSION fields to match accordingly. +OLDEST_SUPPORTED_CHROME = 70 # Released on 2018-10-16 +OLDEST_SUPPORTED_FIREFOX = 55 # Released on 2017-08-08 +OLDEST_SUPPORTED_SAFARI = 120200 # Released on 2019-03-25 # 10.19.0 is the oldest version of node that we do any testing with. # Keep this in sync with the test-node-compat in .circleci/config.yml. OLDEST_SUPPORTED_NODE = 101900 From eceaf7fe269fd79eb2dcee9ef64d5137264b24e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Thu, 14 Aug 2025 19:32:14 +0300 Subject: [PATCH 3/6] update settings docs. --- site/source/docs/tools_reference/settings_reference.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/site/source/docs/tools_reference/settings_reference.rst b/site/source/docs/tools_reference/settings_reference.rst index d8e7116976217..eeab7680e523b 100644 --- a/site/source/docs/tools_reference/settings_reference.rst +++ b/site/source/docs/tools_reference/settings_reference.rst @@ -2860,7 +2860,7 @@ are desired to work. Pass -sMIN_FIREFOX_VERSION=majorVersion to drop support for Firefox versions older than < majorVersion. Firefox 79 was released on 2020-07-28. MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. -Minimum supported value is 50 which was released on 2016-11-15 (see +Minimum supported value is 55 which was released on 2017-08-08 (see feature_matrix.py) Default value: 79 @@ -2880,7 +2880,7 @@ NOTE: Emscripten is unable to produce code that would work in iOS 9.3.5 and older, i.e. iPhone 4s, iPad 2, iPad 3, iPad Mini 1, Pod Touch 5 and older, see https://github.com/emscripten-core/emscripten/pull/7191. MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. -Minimum supported value is 101000 which was released in 2016-09 (see +Minimum supported value is 120200 which was released on 2019-03-25 (see feature_matrix.py). Default value: 150000 @@ -2896,7 +2896,7 @@ This setting also applies to modern Chromium-based Edge, which shares version numbers with Chrome. Chrome 85 was released on 2020-08-25. MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. -Minimum supported value is 55, which was released on 2016-12-01 (see +Minimum supported value is 70, which was released on 2018-10-16 (see feature_matrix.py). Default value: 85 From d45bd70c4749b857d648141af550b095cc202bd0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Thu, 14 Aug 2025 22:33:45 +0300 Subject: [PATCH 4/6] Add note about min mt requirement --- src/settings.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/settings.js b/src/settings.js index 6457e1c40f5b3..cb4790945bb25 100644 --- a/src/settings.js +++ b/src/settings.js @@ -1884,6 +1884,8 @@ var MIN_FIREFOX_VERSION = 79; // NOTE: Emscripten is unable to produce code that would work in iOS 9.3.5 and // older, i.e. iPhone 4s, iPad 2, iPad 3, iPad Mini 1, Pod Touch 5 and older, // see https://github.com/emscripten-core/emscripten/pull/7191. +// Multithreaded Emscripten code will need Safari 12.2 (iPhone 5s+) at minimum, +// with support for DedicatedWorkerGlobalScope.name parameter. // MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. // Minimum supported value is 120200 which was released on 2019-03-25 (see // feature_matrix.py). From 512431615451627757b0827d359afe8d8b71503e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Thu, 14 Aug 2025 22:35:43 +0300 Subject: [PATCH 5/6] Update docs --- site/source/docs/tools_reference/settings_reference.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/site/source/docs/tools_reference/settings_reference.rst b/site/source/docs/tools_reference/settings_reference.rst index eeab7680e523b..07dcd98a20c14 100644 --- a/site/source/docs/tools_reference/settings_reference.rst +++ b/site/source/docs/tools_reference/settings_reference.rst @@ -2879,6 +2879,8 @@ bundled with macOS 10.14.0 Mojave. NOTE: Emscripten is unable to produce code that would work in iOS 9.3.5 and older, i.e. iPhone 4s, iPad 2, iPad 3, iPad Mini 1, Pod Touch 5 and older, see https://github.com/emscripten-core/emscripten/pull/7191. +Multithreaded Emscripten code will need Safari 12.2 (iPhone 5s+) at minimum, +with support for DedicatedWorkerGlobalScope.name parameter. MAX_INT (0x7FFFFFFF, or -1) specifies that target is not supported. Minimum supported value is 120200 which was released on 2019-03-25 (see feature_matrix.py). From c7f99e886562175d9c92db0c46bc2a28953bebbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jukka=20Jyl=C3=A4nki?= Date: Fri, 15 Aug 2025 09:21:57 +0300 Subject: [PATCH 6/6] Fix tests --- test/test_other.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/test_other.py b/test/test_other.py index 7cba06185531c..5d45d8f312ebd 100644 --- a/test/test_other.py +++ b/test/test_other.py @@ -15226,8 +15226,8 @@ def test_reproduce(self): self.assertTextDataIdentical(expected, response) def test_min_browser_version(self): - err = self.expect_fail([EMCC, test_file('hello_world.c'), '-Wno-transpile', '-Werror', '-sWASM_BIGINT', '-sMIN_SAFARI_VERSION=120000']) - self.assertContained('emcc: error: MIN_SAFARI_VERSION=120000 is not compatible with WASM_BIGINT (150000 or above required)', err) + err = self.expect_fail([EMCC, test_file('hello_world.c'), '-Wno-transpile', '-Werror', '-sWASM_BIGINT', '-sMIN_SAFARI_VERSION=130000']) + self.assertContained('emcc: error: MIN_SAFARI_VERSION=130000 is not compatible with WASM_BIGINT (150000 or above required)', err) err = self.expect_fail([EMCC, test_file('hello_world.c'), '-Wno-transpile', '-Werror', '-pthread', '-sMIN_CHROME_VERSION=73']) self.assertContained('emcc: error: MIN_CHROME_VERSION=73 is not compatible with pthreads (74 or above required)', err) @@ -15241,7 +15241,7 @@ def test_signext_lowering(self): self.assertNotContained('--signext-lowering', err) # Specifying an older browser version should trigger the lowering pass - err = self.run_process(cmd + ['-sMIN_SAFARI_VERSION=120000'], stderr=subprocess.PIPE).stderr + err = self.run_process(cmd + ['-sMIN_SAFARI_VERSION=120200'], stderr=subprocess.PIPE).stderr self.assertContained('--signext-lowering', err) err = self.run_process(cmd + ['-sMIN_FIREFOX_VERSION=61'], stderr=subprocess.PIPE).stderr self.assertContained('--signext-lowering', err) @@ -15991,7 +15991,7 @@ def test_no_extra_output(self): def test_browser_too_old(self): err = self.expect_fail([EMCC, test_file('hello_world.c'), '-sMIN_CHROME_VERSION=10']) - self.assertContained('emcc: error: MIN_CHROME_VERSION older than 55 is not supported', err) + self.assertContained('emcc: error: MIN_CHROME_VERSION older than 70 is not supported', err) def test_js_only_settings(self): err = self.run_process([EMCC, test_file('hello_world.c'), '-o', 'foo.wasm', '-sDEFAULT_LIBRARY_FUNCS_TO_INCLUDE=emscripten_get_heap_max'], stderr=PIPE).stderr