Skip to content
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] Implement public hot reload API #48380

Merged
12 commits merged into from
Feb 19, 2021
Merged

[mono] Implement public hot reload API #48380

12 commits merged into from
Feb 19, 2021

Conversation

lambdageek
Copy link
Member

Also add ApplyUpdateSdb that takes byte[] arguments for use with
mono/debugger-libs as its awkward to call a ROS method from the debugger.

Contributes to #45689

This is the mono counterpart of #48366

@dotnet-issue-labeler
Copy link

Note regarding the new-api-needs-documentation label:

This serves as a reminder for when your PR is modifying a ref *.cs file and adding/modifying public APIs, to please make sure the API implementation in the src *.cs file is documented with triple slash comments, so the PR reviewers can sign off that change.

@dotnet-issue-labeler
Copy link

I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label.

@ghost
Copy link

ghost commented Feb 17, 2021

Tagging subscribers to this area: @CoffeeFlux
See info in area-owners.md if you want to be subscribed.

Issue Details

Also add ApplyUpdateSdb that takes byte[] arguments for use with
mono/debugger-libs as its awkward to call a ROS method from the debugger.

Contributes to #45689

This is the mono counterpart of #48366

Author: lambdageek
Assignees: -
Labels:

area-VM-meta-mono, new-api-needs-documentation

Milestone: -

@lambdageek lambdageek changed the title [mono] Use new public hot reload API [mono] Implement public hot reload API Feb 17, 2021
@lambdageek
Copy link
Member Author

Probably going to conflict with the CoreCLR PR since we're both modifying the ref/ assembly, but that's ok, I'll rebase after the other PR goes in.

@lambdageek
Copy link
Member Author

@joj once this is merged, (and there's a new nightly runtime installer) you will need to update your prototype to use

System.Reflection.Metadata.AssemblyExtensions.ApplyUpdateSdb(Assembly assembly, byte[] metadataDelta, byte[] ilDelta, byte[] pdbDelta)

lambdageek and others added 6 commits February 18, 2021 18:44
Also add ApplyUpdateSdb that takes byte[] arguments for use with
mono/debugger-libs as its awkward to call a ROS<byte> method from the debugger.

Contributes to dotnet#45689
…/AssemblyExtensions.cs

Co-authored-by: Marek Safar <marek.safar@gmail.com>
@lambdageek
Copy link
Member Author

@stephentoub I rebased on master picking up @mikem8361 's changes and moved the argument checking to the shared area. Would you mind reviewing again?

@marek-safar leaving ApplyUpdateSdb as we discussed for now.

@mikem8361
Copy link
Member

@lambdageek, are you going to enable the invalid arg testing in runtime\src\libraries\System.Runtime.Loader\tests\AssemblyExtensionsTest.cs? By removing the "SkipOnMono" and "ActiveIssue" attributes?

FYI, to build/run the test on Windows:

call c:\runtime\dotnet.cmd build /t:Test /p:XunitMethodName=System.Reflection.Metadata.AssemblyExtensionsTest.ApplyUpdateInvalidParameters C:\runtime\src\libraries\System.Runtime.Loader\tests\System.Runtime.Loader.Tests.csproj

On Linux/MacOS:

$HOME/runtime/dotnet.sh build /t:Test /p:XunitMethodName=System.Reflection.Metadata.AssemblyExtensionsTest.ApplyUpdateInvalidParameters $HOME/runtime/src/libraries/System.Runtime.Loader/tests/System.Runtime.Loader.Tests.csproj

@lambdageek
Copy link
Member Author

Enabled the ApplyUpdateInvalidParameters test for Mono on all platforms. ActiveIssue for CoreCLR on non-Windows. /cc @mikem8361

@lambdageek
Copy link
Member Author

It's unfortunate that PlatformSpecificAttribute doesn't have a runtime parameter. ActiveIssue isn't really a great fit

@lambdageek lambdageek dismissed mikem8361’s stale review February 19, 2021 04:07

ActiveIssue seems to be working on non-Windows coreclr

@lambdageek
Copy link
Member Author

Is there anything else that should be done before this is merged? If not could someone approve.

@ghost
Copy link

ghost commented Feb 19, 2021

Hello @lambdageek!

Because this pull request has the auto-merge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@ghost ghost merged commit 629ad50 into dotnet:master Feb 19, 2021
@ghost ghost locked as resolved and limited conversation to collaborators Mar 21, 2021
This pull request was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants