[Mono] Initial metadata update support#45612
Merged
lambdageek merged 31 commits intodotnet:masterfrom Jan 11, 2021
Merged
Conversation
51 tasks
|
Tagging subscribers to this area: @CoffeeFlux Issue DetailsFirst part of support for metadata updates. Contributes to #44806 The feature is off by default. To enable, build with
|
08b642f to
e1087a5
Compare
0a18357 to
3c00733
Compare
Co-Authored-By: Bernhard Urban-Forster <[email protected]>
Both samples depend on the roslynildiff tool which should be specified with a RoslynILDiffFullPath property in the .csproj files for the projects.
In the runtime defines cmake ENABLE_METADATA_UPDATE option and sets a preprocessor flag. In System.Private.CoreLib, defines FEATURE_METADATA_UPDATE and uses it to throw a NotSupportedException from LoadMetadataUpdate
Also move execution engine initialization into the main update function and use a MonoError to signal failures (such as if interp inlining is not turned off) instead of asserting at startup.
Use the WasmApp.targets
Log all the unsupported edits, then cancel the update
Keep track of inserted/modified rows for each table in each delta. This will help to use a simpler algorithm to locate effective table rows by keeping track of the logical number of rows in the appended tables
We're going to need to walk backwards from the latest published delta
vargaz
reviewed
Jan 7, 2021
vargaz
reviewed
Jan 7, 2021
vargaz
reviewed
Jan 7, 2021
Member
Author
vargaz
reviewed
Jan 7, 2021
src/mono/netcore/System.Private.CoreLib/src/ILLink/ILLink.Descriptors.xml
Outdated
Show resolved
Hide resolved
vargaz
reviewed
Jan 7, 2021
BrzVlad
reviewed
Jan 8, 2021
Give metadata updates a peek at the interp frames since the LMF so that it can copy the InterpMethods that are currently executing This only works with hybrid and full coop suspend. Preemptive suspend will need another mechanism.
Add a busy thread to demonstrate that interp frames since the last managed frame are visible to the metadata update mechanism and the active method bodies are copied before being invalidated.
BrzVlad
reviewed
Jan 9, 2021
BrzVlad
reviewed
Jan 9, 2021
Member
Author
BrzVlad
approved these changes
Jan 11, 2021
vargaz
approved these changes
Jan 11, 2021
This file contains hidden or 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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
First part of support for metadata updates.
Contributes to #44806
The feature is off by default. To enable, build with
/p:MonoMetadataUpdate=true(e.g../build.sh --os browser /p:MonoMetadataUpdate=true). There are samples insrc/mono/netcore/sample/mbr(see the README - the samples aren't completely standalone and need some external tooling to build) for console (only tested on Mac and Linux) and wasm.There's a demo at https://lambdageek.dev/dl0/