From ad542b244bea3b453a6bda6b59440182c6c14ef2 Mon Sep 17 00:00:00 2001 From: Radek Doulik Date: Mon, 15 Jul 2024 23:09:44 +0200 Subject: [PATCH] [wasm] emscripten bump 3.1.56 (#100334) * [wasm] Bump emscripten to 3.1.56 * Replace Module.asm with Module.wasmExports Module.asm was removed, use wasmExports instead. Context: https://github.com/emscripten-core/emscripten/pull/19816 * Updates for .native.worker.js -> mjs rename Context: https://github.com/emscripten-core/emscripten/pull/21041 * Update deps * Add general testing feed * Update mode deps * Update path * Use current python packages for now, we don't have newer ones The current names 3.1.34 are new enough * Keep using llvm 16 for runtime and aot compiler * Add -Wno-pre-c11-compat only for browser * Temporarily disable version checks to get further * Temporarily disable version checks to get further #2 * Disable -Wunused-command-line-argument * Update emsdk deps * Update icu dependency * Revert "Temporarily disable version checks to get further #2" This reverts commit 3f8834f2a83405bdb46ffe4ae46560ce7c8755e3. * Revert "Temporarily disable version checks to get further" This reverts commit fe1e5c643c6ab4bbfeb1af06f1f13492722825b9. * Fix emsdk check We use system python on osx too * Workaround wasm-opt crash * Workaround wasm-opt crash * Workaround wasm-opt crash * Fix WBT test * Feedback * Update ICU dependency * Update emscripten deps * Revert "Workaround wasm-opt crash" This reverts commit 200cf3b3915d7e308414387628049cc710196992. * Revert "Workaround wasm-opt crash" This reverts commit 4530edfdcc64dd60d16f276a58fb7e3e5ede867d. * Revert "Workaround wasm-opt crash" This reverts commit 3593c41798f6c667a1778859f5576d8cfc723d5d. * Increase tests timeout * Show test progress * Increase MT library tests timeout * Disable WBT tests with SkiaSharp * Increase helix tests timeout on browser * Increase WBT timeout * Increase initial heap sizes * Fix mono_wasm_load_runtime cwrap signature Fixes: `Uncaught ExitStatus: Assertion failed: stringToUTF8Array expects a string (got number)` * Enable XunitShowProgress for threading tasks tests * Try to reduce number of parallel AOT compilations To check whether it will improve memory issues on CI * Use new docker image for helix/windows tests * Revert "Try to reduce number of parallel AOT compilations" This reverts commit 5d9a6d2352e1df268a591320ac36ed62b71f8c91. * Reduce the timeouts * Reduce intitial heap size * use active issues for MT * Remove testing channel from nuget config, update deps * Update emsdk and icu dependencies --------- Co-authored-by: Larry Ewing Co-authored-by: pavelsavara --- eng/Version.Details.xml | 12 ++++++------ eng/Versions.props | 6 +++--- eng/liveBuilds.targets | 4 ++-- eng/pipelines/libraries/helix-queues-setup.yml | 2 +- .../Microsoft.NETCore.App/Directory.Build.props | 2 +- .../System.Buffers.Tests.csproj | 1 + .../System.Threading.Tasks.Tests.csproj | 1 + src/libraries/sendtohelixhelp.proj | 1 + src/mono/browser/browser.proj | 11 +++++++---- src/mono/browser/build/BrowserWasmApp.targets | 6 +++--- src/mono/browser/emscripten-version.txt | 2 +- src/mono/browser/runtime/CMakeLists.txt | 2 +- src/mono/browser/runtime/cwraps.ts | 6 +++--- src/mono/browser/runtime/es6/dotnet.es6.pre.js | 2 +- src/mono/browser/runtime/jiterpreter-jit-call.ts | 2 +- src/mono/browser/runtime/jiterpreter-support.ts | 4 ++-- src/mono/browser/runtime/loader/assets.ts | 1 + src/mono/browser/runtime/pthreads/ui-thread.ts | 1 + src/mono/browser/runtime/types/internal.ts | 2 +- .../wasm/Wasm.Build.Tests/Blazor/MiscTests.cs | 1 + src/mono/wasm/Wasm.Build.Tests/BuildTestBase.cs | 2 +- .../Wasm.Build.Tests/Common/BuildEnvironment.cs | 2 +- .../wasm/Wasm.Build.Tests/NativeLibraryTests.cs | 1 + .../TestMainJsProjectProvider.cs | 6 +++--- .../WasmSdkBasedProjectProvider.cs | 8 ++++---- src/mono/wasm/build/WasmApp.Common.targets | 2 +- ...ntsWebAssemblyApplicationBuilderExtensions.cs | 1 + .../WasmOnAspNetCore/AspNetCoreServer/Program.cs | 1 + src/native/libs/CMakeLists.txt | 4 ++++ .../AssetsComputingHelper.cs | 3 ++- .../BootJsonBuilderHelper.cs | 2 +- .../ComputeWasmBuildAssets.cs | 5 +++-- .../ComputeWasmPublishAssets.cs | 16 +++++++++------- src/tasks/WasmAppBuilder/WasmAppBuilder.cs | 2 +- 34 files changed, 72 insertions(+), 52 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 32b119ad8b537..8229ab31c8968 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,8 +1,8 @@ - + https://github.com/dotnet/icu - 42787a07ecba682549f520293bb5a6941bdccb50 + c8db7547bc0a021ffd262b3449f5b0343894b32b https://github.com/dotnet/msquic @@ -68,14 +68,14 @@ 7e4af02521473d89d6144b3da58fef253e498974 - + https://github.com/dotnet/emsdk - d3583522209829d1ed0440662ba136c7b7700b16 + 99ea0c06b84d3084d090da537080dd35d2a193cf - + https://github.com/dotnet/emsdk - d3583522209829d1ed0440662ba136c7b7700b16 + 99ea0c06b84d3084d090da537080dd35d2a193cf diff --git a/eng/Versions.props b/eng/Versions.props index 8b19e3de2d129..b9b6c8e08186d 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -216,7 +216,7 @@ 9.0.0-preview.7.24357.2 - 9.0.0-preview.7.24358.1 + 9.0.0-preview.7.24365.2 2.3.5 9.0.0-alpha.1.24167.3 @@ -239,7 +239,7 @@ Note: when the name is updated, make sure to update dependency name in eng/pipelines/common/xplat-setup.yml like - DarcDependenciesChanged.Microsoft_NET_Workload_Emscripten_Current_Manifest-9_0_100_Transport --> - 9.0.0-preview.7.24352.2 + 9.0.0-preview.7.24365.1 $(MicrosoftNETWorkloadEmscriptenCurrentManifest90100TransportVersion) 9.0.0-preview.7.24352.2 @@ -262,6 +262,6 @@ 9.0.0-alpha.1.24175.1 $(MicrosoftNETRuntimeEmscriptenVersion) $(runtimewinx64MicrosoftNETCoreRuntimeWasmNodeTransportPackageVersion) - 3.1.34 + 3.1.56 diff --git a/eng/liveBuilds.targets b/eng/liveBuilds.targets index fce021e7b9970..db8aee3799b44 100644 --- a/eng/liveBuilds.targets +++ b/eng/liveBuilds.targets @@ -215,9 +215,9 @@ $(LibrariesNativeArtifactsPath)segmentation-rules.json;" IsNative="true" /> - - + diff --git a/src/libraries/System.Runtime/tests/System.Buffers.Tests/System.Buffers.Tests.csproj b/src/libraries/System.Runtime/tests/System.Buffers.Tests/System.Buffers.Tests.csproj index 66ae6833a50eb..113d56e6f4363 100644 --- a/src/libraries/System.Runtime/tests/System.Buffers.Tests/System.Buffers.Tests.csproj +++ b/src/libraries/System.Runtime/tests/System.Buffers.Tests/System.Buffers.Tests.csproj @@ -6,6 +6,7 @@ $(NetCoreAppCurrent) + true 1 diff --git a/src/libraries/System.Runtime/tests/System.Threading.Tasks.Tests/System.Threading.Tasks.Tests.csproj b/src/libraries/System.Runtime/tests/System.Threading.Tasks.Tests/System.Threading.Tasks.Tests.csproj index 4b916c09bb4b3..2f832312d7e2d 100644 --- a/src/libraries/System.Runtime/tests/System.Threading.Tasks.Tests/System.Threading.Tasks.Tests.csproj +++ b/src/libraries/System.Runtime/tests/System.Threading.Tasks.Tests/System.Threading.Tasks.Tests.csproj @@ -6,6 +6,7 @@ <_WasmPThreadPoolUnusedSize>10 + true diff --git a/src/libraries/sendtohelixhelp.proj b/src/libraries/sendtohelixhelp.proj index 3608f1cae63d0..81a3ac4d71097 100644 --- a/src/libraries/sendtohelixhelp.proj +++ b/src/libraries/sendtohelixhelp.proj @@ -39,6 +39,7 @@ '$(Scenario)' == 'gcstress0xc_jitminopts_heapverify1'">06:00:00 <_workItemTimeout Condition="'$(_workItemTimeout)' == '' and '$(TargetsAppleMobile)' == 'true'">01:15:00 <_workItemTimeout Condition="'$(_workItemTimeout)' == '' and '$(TargetOS)' == 'android'">00:30:00 + <_workItemTimeout Condition="'$(_workItemTimeout)' == '' and '$(TargetOS)' == 'browser'">00:30:00 <_workItemTimeout Condition="'$(Scenario)' == '' and '$(_workItemTimeout)' == '' and ('$(TargetArchitecture)' == 'arm64' or '$(TargetArchitecture)' == 'arm')">00:45:00 <_workItemTimeout Condition="'$(Scenario)' != '' and '$(_workItemTimeout)' == '' and ('$(TargetArchitecture)' == 'arm64' or '$(TargetArchitecture)' == 'arm')">01:00:00 <_workItemTimeout Condition="'$(Scenario)' == '' and '$(_workItemTimeout)' == '' and ('$(TestScope)' == 'outerloop' or '$(TestScope)' == 'all')">00:20:00 diff --git a/src/mono/browser/browser.proj b/src/mono/browser/browser.proj index 47a351fb53b41..e9923f10d4831 100644 --- a/src/mono/browser/browser.proj +++ b/src/mono/browser/browser.proj @@ -217,6 +217,8 @@ + + @@ -277,6 +279,7 @@ 5MB + <_EmccLinkFlags Include="-Wno-unused-command-line-argument" /> <_EmccLinkFlags Include="-s INITIAL_MEMORY=$(EmccInitialHeapSize)" /> <_EmccLinkFlags Include="-s STACK_SIZE=$(EmccStackSize)" /> <_EmccCommonFlags Condition="'$(WasmEnableThreads)' == 'true'" Include="-s USE_PTHREADS=1" /> @@ -294,7 +297,7 @@ <_EmccLinkFlags Include="--source-map-base http://example.com" /> <_EmccLinkFlags Include="-s WASM_BIGINT=1" /> <_EmccLinkFlags Include="-s EXPORT_NAME="'createDotnetRuntime'"" /> - <_EmccLinkFlags Include="-s MODULARIZE=1"/> + <_EmccLinkFlags Include="-s MODULARIZE=1" /> <_EmccLinkFlags Include="-s ENVIRONMENT="web,webview,worker,node,shell"" />