-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[mono] merge wasm-threading-eventpipe into main #68232
Merged
lambdageek
merged 139 commits into
dotnet:main
from
lambdageek:wasm-threading-eventpipe
Apr 26, 2022
Merged
Changes from all commits
Commits
Show all changes
139 commits
Select commit
Hold shift + click to select a range
0a6c904
Initial changes for emscripten 2.0.34
radekdoulik 1c2f989
Use emcc-link.rsp in build targets
radekdoulik f74d8b9
Use updated docker images
radekdoulik 20f59e5
Fix compiler warnings
31197d9
Put `--profiling-funcs` to `_EmccLinkFlags`
radekdoulik 2063241
Fix build
radekdoulik 6aed1c5
Add shell to the environment
radekdoulik 1f0048f
Merge remote-tracking branch 'origin/main' into pr-emscripten-34-bump
radekdoulik 17c0117
Merge remote-tracking branch 'remotes/origin/main' into pr-emscripten…
radekdoulik 11e2ce5
Add emcc-link.rsp to PlatformManifestFileEntry
radekdoulik 3eb44cf
Feedback
radekdoulik c0e4d84
Merge remote-tracking branch 'remotes/origin/main' into pr-emscripten…
radekdoulik 460d09a
Bump emscripten version
radekdoulik 6f7d0c2
Bump llvm package version and use its libclang
radekdoulik b9c7488
Merge remote-tracking branch 'remotes/origin/main' into pr-emscripten…
radekdoulik e089ab1
Use newer docker images with emscripten 3.1.1
radekdoulik 1cfd8bb
Merge remote-tracking branch 'remotes/origin/main' into pr-emscripten…
radekdoulik 01c9516
Remove unused variable
radekdoulik ccbf541
Merge remote-tracking branch 'upstream/main' into wasm-threaded-build
731818a
Add runtime support for threads in the wasm build
7142965
Prevent runtime from starting twice when loaded in a web worker
kg f83f093
Automatically populate the emscripten mainScriptUrlOrBlob property so…
kg 01cbb8d
Add compatibility shim so that emscripten's generated worker.js can p…
kg e7162e7
Checkpoint
kg 7380334
Bring back threadpool and add some tracing in diagnostics
3121ca5
Add comments and fix a typo
kg 2cd8459
Introduce 'MonoObjectRef' ts type. Migrate mono_string_intern to not …
kg e483d20
Checkpoint (strings are broken for some reason)
kg 1bff860
Fix string interning
kg 29ae4f7
Checkpoint
kg 54fa62f
Migrate ObjectToString and GetDateValue
kg 50b5201
Checkpoint gc safe/unsafe region work
kg 094ce5b
Checkpoint
kg f49b008
More ref conversion
kg 19c4b01
Checkpoint (broken?)
kg 727c490
Fix missing method
kg d283c87
Checkpoint
kg 6c69292
Checkpoint
kg a28c63c
Checkpoint (broken)
kg 1315a4a
Checkpoint (broken)
kg 2e2fc35
Checkpoint
kg 2be1022
Checkpoint
kg 25cc304
Checkpoint
kg 463a680
Checkpoint (broken)
kg f950d2d
Fix incorrect signatures
kg 767a559
Checkpoint
kg d94bbb1
Fix lint
kg 0996c1d
Add new 'R' signature char for 'ref object'
kg f4020b2
Checkpoint
kg 503f4af
Checkpoint
kg 8f639ec
Checkpoint
kg daefa4a
Checkpoint
kg 05993d8
Remove AddEventListener and RemoveEventListener
kg ae8d4e9
Checkpoint
kg dd9836b
Checkpoint
kg da0011c
Checkpoint
kg dbed688
eslint fixes
kg 002f60d
Checkpoint
kg c261e34
Update call_method signature to avoid passing raw object pointers
kg faa94e9
Ref-ify one websocket API and fix types and incorrect rooting of two …
kg ef58f32
Checkpoint
kg e864fa8
Deprecation metadata
kg 7a80489
More ref
kg 5563e01
More ref
kg 23bcf95
Remove outdated comments
kg ba6f738
Convert typed_array_new to ref
kg 2684213
Add volatile modifiers, satisfy eslint
kg a87cdbc
Update src/mono/wasm/runtime/corebindings.c
kg 9f20277
Missing conflict
af5aee4
Merge remote-tracking branch 'upstream/main' into wasm-eventpipe
2a5553a
Fix build, set coop gc, and always copy dotnet.worker.js when it's ar…
06da696
Disable sample profiler, add some functions that were missing from ka…
e4b05eb
Add safepoint around ep_rt_wait_event_set. Tweak sample to explicitl…
67c70ac
[gc] Start the GC Finalizer thread on threaded WASM
lambdageek 0f6f521
[mono] add GC Unsafe in mono_assembly_load; remove in EventPipe
lambdageek 622c457
Merge remote-tracking branch 'origin/main' into wasm-threading-eventpipe
lambdageek 5af1f5c
post-merge cleanup: delete duplicated definitions
lambdageek 7bbaf94
[sample] Env vars should be stringy
lambdageek 4174adc
updated dotnet.d.ts
lambdageek 736a610
Add mono_threads_wasm_async_run_in_main_thread; do background work on…
lambdageek 8eb8011
[mono] Fix non-threaded wasm build
lambdageek 6fe4374
Add a System.Threading.Thread.WebAssembly.Threading ref assembly
lambdageek 06ee494
Update the browser sample to use System.Threading.Thread.WebAssembly.…
lambdageek 07bf28f
what is oob-all for? don't add thread wasm ref assembly there
lambdageek 6eb923d
Rationalize System.Threading.Thread build
lambdageek 7844a91
only turn on analyzers for the browser sample
lambdageek 5cd594b
Make a single Microsoft.NET.WebAssembly.Threading nupkg
lambdageek 75166a0
works: sample has ProjectReference to the Microsoft.NET.WebAssembly.T…
lambdageek 3967d2c
Add System.Threading.ThreadPool.WebAssembly.Threading ref assembly
lambdageek a21b1ac
ThreadPool: throw PNSE if no thread start
lambdageek 204dbfb
Update wasm threads.md
lambdageek b02fd66
apicompat: correct warnings for System.Threading.ThreadPool
lambdageek 8417c7f
Add dotnet.worker.js to the runtime pack; update PlatformManifestFile…
lambdageek 5c52e7d
[wasm] startup: detect Blazor dotnet.[version].[hash].js location
lambdageek 0b3755c
one more fix to Microsoft.NET.WebAssembly.Threading
lambdageek 1a3cddc
rename sample to browser-mt-eventpipe
lambdageek b6bc2bc
bring back unmodified browser sample
lambdageek 4dd92a8
update browser-mt-eventpipe sample to use ref assembly refs
lambdageek 0baebbb
Merge remote-tracking branch 'origin/main' into wasm-threading-eventpipe
lambdageek 873d70f
Use correct ifdef in AppContext.AnyOS.cs
lambdageek bc16fdd
[build] support WasmEnableThreads and WasmEnablePerfTracing
lambdageek 352405d
Only add the portable threadpool on wasm if threading is enabled
lambdageek 990f097
rename browser-mt-eventpipe csproj and main assembly
lambdageek ba9a9a6
fix /p:WasmEnableThreads=false build after merge
lambdageek 16621b8
now fix the WasmEnableThreads=true build
lambdageek 3f616f9
we need two ThreadPoolBoundHandle implementation stubs
lambdageek 1c3724a
Add a System.Diagnostics.Tracing ref assembly gated by FeatureWasmPer…
lambdageek e52c9b7
[eventpipe] use the correct cmake option name
lambdageek 9d127df
revert debug printf and commented out code
lambdageek 44f18ff
turn off additional logging
lambdageek f7d8c1a
hack: set FeatureWasmPerfTracing in the browser-mt-eventpipe sample
lambdageek b0ce4e9
remove unused variable
lambdageek fea5058
remove unneeded configure checks
lambdageek f27f834
revert line damage; add better comment in export.ts
lambdageek ef6477f
Exclude Microsoft.NET.WebAssembly.Threading from testPackages.proj
lambdageek eed9c39
review feedback
lambdageek d8a5afb
Apply suggestions from code review
lambdageek 79437a5
Merge branch 'main' into wasm-threading-eventpipe
lambdageek f8eddc9
Use a testPackages settings file to skip package runtime item verific…
lambdageek 47413d4
remove SIZEOF_VOID_P == 7 check
lambdageek 28068a3
remove unneeded Directory.Build.props for ref package
lambdageek 52bebbc
use one ProjectReference item to share metadata for the ref assemblies
lambdageek ea174d3
remove ProjectReference comment and NoTargetsDoNotReferenceOutputAsse…
lambdageek 2716d3c
Remove unneeded target
lambdageek 0687599
packaging simplification
lambdageek 52e05a1
move and rename UpdateExperimentalRefAssemblyFileVersion target
lambdageek 0cfbc2b
Assorted code review nits
lambdageek 262ad4e
Don't build/pack the multi-threaded sample on single-threaded runtime
lambdageek cb2afa5
remove gratuitous debug printfs
lambdageek dc1f1f6
Apply suggestions from code review
lambdageek de94606
Merge remote-tracking branch 'origin/main' into wasm-threading-eventpipe
lambdageek edbb341
merge followup: nullable is enabled by default now
lambdageek 96e8f2f
make eslint happy
lambdageek 1f2eda0
include wasm-config.h in wasm runtime host
lambdageek d44167c
add wasm-config.h directory to includde directories
lambdageek abf8335
include wasm-config.h into the runtime pack
lambdageek 98467bf
Add wasm-config.h to manifest
lambdageek 051356d
put wasm-config.h into include/wasm from the outset
lambdageek 71c9c6f
put back noExitRuntime replacement for CJS
lambdageek File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
...ibraries/Microsoft.NET.WebAssembly.Threading/src/Microsoft.NET.WebAssembly.Threading.proj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<Project Sdk="Microsoft.Build.NoTargets"> | ||
<PropertyGroup> | ||
<TargetFramework>$(NetCoreAppCurrent)</TargetFramework> | ||
<IncludeBuildOutput>true</IncludeBuildOutput> | ||
<DebugSymbols>false</DebugSymbols> | ||
<DebugType>none</DebugType> | ||
<NoTargetsDoNotReferenceOutputAssemblies>false</NoTargetsDoNotReferenceOutputAssemblies> | ||
<DisablePackageBaselineValidation>true</DisablePackageBaselineValidation> | ||
<IsPackable>true</IsPackable> | ||
<PackageDescription>Exposes Threading APIs for WebAssembly projects</PackageDescription> | ||
<!-- XXX FIXME: NU5128 suppresses a really scary message about missing net7.0 dependencies --> | ||
<NoWarn>$(NoWarn);NU5128;NU5131</NoWarn> | ||
<!-- Place assemblies in the nuget ref folder --> | ||
<BuildOutputTargetFolder>ref</BuildOutputTargetFolder> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference | ||
Include="$(LibrariesProjectRoot)System.Threading.Thread.WebAssembly.Threading\ref\System.Threading.Thread.WebAssembly.Threading.csproj; | ||
$(LibrariesProjectRoot)System.Threading.ThreadPool.WebAssembly.Threading\ref\System.Threading.ThreadPool.WebAssembly.Threading.csproj; | ||
$(LibrariesProjectRoot)System.Diagnostics.Tracing.WebAssembly.PerfTracing\ref\System.Diagnostics.Tracing.WebAssembly.PerfTracing.csproj" | ||
Pack="true" PrivateAssets="all" Private="true" IncludeReferenceAssemblyInPackage="true" /> | ||
</ItemGroup> | ||
|
||
</Project> |
22 changes: 22 additions & 0 deletions
22
...ing.WebAssembly.PerfTracing/ref/System.Diagnostics.Tracing.WebAssembly.PerfTracing.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks> | ||
<TargetFramework>$(NetCoreAppCurrent)</TargetFramework> | ||
<FeatureWasmPerfTracing>true</FeatureWasmPerfTracing> | ||
<AssemblyName>System.Diagnostics.Tracing</AssemblyName> | ||
<!-- tell references.targets to bump the assembly version --> | ||
<IsExperimentalRefAssembly>true</IsExperimentalRefAssembly> | ||
<!-- Disable all binplacing since this assembly will clash with the real ref assembly --> | ||
<EnableBinPlacing>false</EnableBinPlacing> | ||
<StrongNameKeyId>Microsoft</StrongNameKeyId> | ||
<IncludePlatformAttributes>true</IncludePlatformAttributes> | ||
<DefineConstants Condition="'$(FeatureWasmPerfTracing)' == 'true'">$(DefineConstants);FEATURE_WASM_PERFTRACING</DefineConstants> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Compile Include="..\..\System.Diagnostics.Tracing\ref\System.Diagnostics.Tracing.cs" /> | ||
<Compile Include="..\..\System.Diagnostics.Tracing\ref\System.Diagnostics.Tracing.Counters.cs" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ProjectReference Include="..\..\System.Runtime\ref\System.Runtime.csproj" PrivateAssets="all" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
src/libraries/System.Diagnostics.Tracing/src/ApiCompatBaseline.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
Compat issues with assembly System.Diagnostics.Tracing: | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.DiagnosticCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.EventCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.IncrementingEventCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.IncrementingPollingCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.PollingCounter' in the contract but not the implementation. | ||
Total Issues: 4 |
7 changes: 6 additions & 1 deletion
7
src/libraries/System.Diagnostics.Tracing/src/MatchingRefApiCompatBaseline.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,11 @@ | ||
Compat issues with assembly System.Diagnostics.Tracing: | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.DiagnosticCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.EventCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.IncrementingEventCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.IncrementingPollingCounter' in the contract but not the implementation. | ||
CannotRemoveAttribute : Attribute 'System.Runtime.Versioning.UnsupportedOSPlatformAttribute' exists on 'System.Diagnostics.Tracing.PollingCounter' in the contract but not the implementation. | ||
MembersMustExist : Member 'protected void System.Diagnostics.Tracing.EventCounter.Flush()' does not exist in the reference but it does exist in the implementation. | ||
CannotMakeTypeAbstract : Type 'System.Diagnostics.Tracing.EventListener' is abstract in the reference but is not abstract in the implementation. | ||
CannotMakeMoreVisible : Visibility of member 'System.Diagnostics.Tracing.EventListener..ctor()' is 'protected' in the reference but 'public' in the implementation. | ||
CannotMakeMoreVisible : Visibility of member 'System.Diagnostics.Tracing.EventListener.EventSourceIndex(System.Diagnostics.Tracing.EventSource)' is 'protected' in the reference but 'public' in the implementation. | ||
Total Issues: 4 | ||
Total Issues: 8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be predicated on FeatureWasmThreads too, like the overlapped one is?