diff --git a/emcc.py b/emcc.py index 9eebdb910f15b..e08ccf0cac286 100755 --- a/emcc.py +++ b/emcc.py @@ -1790,9 +1790,7 @@ def include_and_export(name): # Enable minification of wasm imports and exports when appropriate, if we # are emitting an optimized JS+wasm combo (then the JS knows how to load the minified names). # Things that process the JS after this operation would be done must disable this. - # For example, ASYNCIFY_LAZY_LOAD_CODE needs to identify import names, and wasm2js - # needs to use the getTempRet0 imports (otherwise, it may create new ones to replace - # the old, which would break). + # For example, ASYNCIFY_LAZY_LOAD_CODE needs to identify import names. if will_metadce(options) and \ shared.Settings.OPT_LEVEL >= 2 and \ shared.Settings.DEBUG_LEVEL <= 2 and \ @@ -1803,7 +1801,6 @@ def include_and_export(name): not shared.Settings.RELOCATABLE and \ not target.endswith(WASM_ENDINGS) and \ not shared.Settings.ASYNCIFY_LAZY_LOAD_CODE and \ - not shared.Settings.WASM2JS and \ shared.Settings.MINIFY_ASMJS_EXPORT_NAMES: shared.Settings.MINIFY_WASM_IMPORTS_AND_EXPORTS = 1 # in fastcomp it's inconvenient to minify module names as there is the diff --git a/tests/code_size/hello_webgl2_fastcomp_asmjs.json b/tests/code_size/hello_webgl2_fastcomp_asmjs.json index a4f5c9dff4939..b194eeace2c63 100644 --- a/tests/code_size/hello_webgl2_fastcomp_asmjs.json +++ b/tests/code_size/hello_webgl2_fastcomp_asmjs.json @@ -2,11 +2,11 @@ "a.html": 580, "a.html.gz": 382, "a.js": 5321, - "a.js.gz": 2509, + "a.js.gz": 2510, "a.mem": 321, "a.mem.gz": 219, "a.asm.js": 9814, "a.asm.js.gz": 3544, - "total": 16041, - "total_gz": 6654 + "total": 16036, + "total_gz": 6655 } diff --git a/tests/code_size/hello_webgl2_fastcomp_wasm.json b/tests/code_size/hello_webgl2_fastcomp_wasm.json index 9b3cb7f5afbe6..e5099dad28556 100644 --- a/tests/code_size/hello_webgl2_fastcomp_wasm.json +++ b/tests/code_size/hello_webgl2_fastcomp_wasm.json @@ -5,6 +5,6 @@ "a.js.gz": 2535, "a.wasm": 8004, "a.wasm.gz": 4376, - "total": 13860, + "total": 13855, "total_gz": 7288 } diff --git a/tests/code_size/hello_webgl2_wasm2js.json b/tests/code_size/hello_webgl2_wasm2js.json index 1c6e6d8325faa..3027fa2d84556 100644 --- a/tests/code_size/hello_webgl2_wasm2js.json +++ b/tests/code_size/hello_webgl2_wasm2js.json @@ -1,10 +1,10 @@ { "a.html": 588, "a.html.gz": 386, - "a.js": 23760, - "a.js.gz": 8899, + "a.js": 22340, + "a.js.gz": 8620, "a.mem": 3168, "a.mem.gz": 2711, - "total": 27514, - "total_gz": 11996 + "total": 26096, + "total_gz": 11717 } diff --git a/tests/code_size/hello_webgl_fastcomp_asmjs.json b/tests/code_size/hello_webgl_fastcomp_asmjs.json index 1e8677d8349a3..68f3ef2f88e3a 100644 --- a/tests/code_size/hello_webgl_fastcomp_asmjs.json +++ b/tests/code_size/hello_webgl_fastcomp_asmjs.json @@ -2,11 +2,11 @@ "a.html": 580, "a.html.gz": 382, "a.js": 4867, - "a.js.gz": 2352, + "a.js.gz": 2353, "a.mem": 321, "a.mem.gz": 219, "a.asm.js": 9814, "a.asm.js.gz": 3544, - "total": 15587, - "total_gz": 6497 + "total": 15582, + "total_gz": 6498 } diff --git a/tests/code_size/hello_webgl_fastcomp_wasm.json b/tests/code_size/hello_webgl_fastcomp_wasm.json index d58bee77c507f..e8d1ff3d250d0 100644 --- a/tests/code_size/hello_webgl_fastcomp_wasm.json +++ b/tests/code_size/hello_webgl_fastcomp_wasm.json @@ -2,9 +2,9 @@ "a.html": 563, "a.html.gz": 377, "a.js": 4774, - "a.js.gz": 2356, + "a.js.gz": 2357, "a.wasm": 8004, "a.wasm.gz": 4376, - "total": 13346, - "total_gz": 7109 + "total": 13341, + "total_gz": 7110 } diff --git a/tests/code_size/hello_webgl_wasm2js.json b/tests/code_size/hello_webgl_wasm2js.json index d7f50b8d75fa1..ae433ab8b0b9c 100644 --- a/tests/code_size/hello_webgl_wasm2js.json +++ b/tests/code_size/hello_webgl_wasm2js.json @@ -1,10 +1,10 @@ { "a.html": 588, "a.html.gz": 386, - "a.js": 23250, - "a.js.gz": 8735, + "a.js": 21827, + "a.js.gz": 8454, "a.mem": 3168, "a.mem.gz": 2711, - "total": 27004, - "total_gz": 11832 + "total": 25583, + "total_gz": 11551 } diff --git a/tests/code_size/hello_world_wasm2js.json b/tests/code_size/hello_world_wasm2js.json index b96ecbe162255..282acf4254f8b 100644 --- a/tests/code_size/hello_world_wasm2js.json +++ b/tests/code_size/hello_world_wasm2js.json @@ -1,10 +1,10 @@ { "a.html": 697, "a.html.gz": 437, - "a.js": 2021, - "a.js.gz": 908, + "a.js": 1911, + "a.js.gz": 871, "a.mem": 6, "a.mem.gz": 32, - "total": 2724, - "total_gz": 1377 + "total": 2614, + "total_gz": 1340 } diff --git a/tests/code_size/random_printf_fastcomp_asmjs.json b/tests/code_size/random_printf_fastcomp_asmjs.json index c05f78dee20a5..e021cb245977b 100644 --- a/tests/code_size/random_printf_fastcomp_asmjs.json +++ b/tests/code_size/random_printf_fastcomp_asmjs.json @@ -1,6 +1,6 @@ { "a.html": 2898, "a.html.gz": 1224, - "total": 2907, + "total": 2898, "total_gz": 1224 } diff --git a/tests/code_size/random_printf_fastcomp_wasm.json b/tests/code_size/random_printf_fastcomp_wasm.json index ddad3d4d71c4a..1bbef21eeafbf 100644 --- a/tests/code_size/random_printf_fastcomp_wasm.json +++ b/tests/code_size/random_printf_fastcomp_wasm.json @@ -1,6 +1,6 @@ { "a.html": 14026, "a.html.gz": 7470, - "total": 14059, + "total": 14026, "total_gz": 7470 } diff --git a/tests/code_size/random_printf_wasm.json b/tests/code_size/random_printf_wasm.json index 1b6c3b98b572f..1283ae1a2dab3 100644 --- a/tests/code_size/random_printf_wasm.json +++ b/tests/code_size/random_printf_wasm.json @@ -1,6 +1,6 @@ { "a.html": 13715, "a.html.gz": 7366, - "total": 13707, + "total": 13715, "total_gz": 7366 } diff --git a/tests/code_size/random_printf_wasm2js.json b/tests/code_size/random_printf_wasm2js.json index 6e15ffbec5c30..9faf1e6f24c1a 100644 --- a/tests/code_size/random_printf_wasm2js.json +++ b/tests/code_size/random_printf_wasm2js.json @@ -1,6 +1,6 @@ { - "a.html": 19732, - "a.html.gz": 8241, - "total": 19732, - "total_gz": 8241 + "a.html": 19537, + "a.html.gz": 8171, + "total": 19537, + "total_gz": 8171 }