-
Notifications
You must be signed in to change notification settings - Fork 4.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[wasm-mt] Emscripten SDK runtime pack is missing multi-threaded static libraries #75263
Comments
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsIn dotnet/emsdk#43 we removed Unfortunately this means that We should either put the libraries back in the main SDK, or figure out how to provide an additional nuget with the threaded libs along with required build flags to make
Part of #74654
|
Not sure if we will be able to do this in time for 7, or if it will have to wait until 8 |
A workaround is for users to manually copy the required libraries from an EMSDK install
|
Report from
Just the ✅ total is around 11 megabytes Adding the ❓is near 17 with libwasmfs making up the bulk of the extra space |
@lewing what do you think about a separate (OOB) nuget that just has the mt libs and some SDK.props that injects emscipten linker flags? So to do a multi-threaded native build one would have to do something like this: <PropertyGroup>
<WasmEnableThread>true</WasmEnableThread>
<WasmBuildNative>true</WasmBuildNative>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.NET.Runtime.Emscripten.3.0.12.Threading.Sdk" Version="7.0.0" IncludeAssets="build" />
</ItemGroup> |
no need, we can do all that in the workload invisibly, the complicated part is packaging it and setting the appropriate compiler options. |
The steps are essentially adding the threading package to the emsdk build, and referencing it in the emscripten manifest when WasmEnableThreads is set. It's props should add the required flags and paths to the emcc options. |
@lewing I was thinking OOB in case we don't make it by RTM 😁 |
I'm looking at the emsdk build right now - moving the -mt.a files out of the way (instead of deleting) and making a new nuget seems straightforward. I'll try to have something to show by tomorrow or Monday |
either way it starts with making the pack ;) |
bit of a change of plans. Emscripten doesn't make it easy to look for some (but not all) system libs in another directory. So we're going to spin out the whole emscripten cache into a separate nupkg instead and put both normal and -mt libraries in there |
#208) Spin out the emscripten system libraries cache into a separate nupkg. - Split up the Emscripten SDK by moving the system libraries cache into a separate nupkg. - make a new Emscripten Cache SDK that includes just the cache directory - the Cache SDK overrides the WasmCachePath (if it's not set by the user) to point into the Cache SDK we leave the mt multithreaded libraries in the cache. (But we remove the ww WebWorker (non-pthread) Emscripten API libraries) Addresses dotnet/runtime#75263
Fixed in emsdk. Now we wait for flow... |
Spin out the emscripten system libraries cache into a separate nupkg. - Split up the Emscripten SDK by moving the system libraries cache into a separate nupkg. - make a new Emscripten Cache SDK that includes just the cache directory - the Cache SDK overrides the WasmCachePath (if it's not set by the user) to point into the Cache SDK we leave the mt multithreaded libraries in the cache. (But we remove the ww WebWorker (non-pthread) Emscripten API libraries) Addresses dotnet/runtime#75263
Spin out the emscripten system libraries cache into a separate nupkg. - Split up the Emscripten SDK by moving the system libraries cache into a separate nupkg. - make a new Emscripten Cache SDK that includes just the cache directory - the Cache SDK overrides the WasmCachePath (if it's not set by the user) to point into the Cache SDK we leave the mt multithreaded libraries in the cache. (But we remove the ww WebWorker (non-pthread) Emscripten API libraries) Addresses dotnet/runtime#75263
In dotnet/emsdk#43 we removed
*-mt.a
from the emscripten sysroot.Unfortunately this means that
/p:WasmBuildNative=true
does not work for multi-threaded builds.We should either put the libraries back in the main SDK, or figure out how to provide an additional nuget with the threaded libs along with required build flags to make
emcc
look for them in another directory.Part of #74654
The text was updated successfully, but these errors were encountered: