Skip to content

Conversation

@lambdageek
Copy link
Member

@lambdageek lambdageek commented Mar 25, 2021

Backport of #50248 to release/6.0-preview3 (backported by hand)

Customer Impact

Avoids unexpected hot reload behavior in BlazorWasm projects. Note dotnet/aspnetcore#31216 - the customers won't get hot reload by default in Preview 3, they will have to explicitly opt in.

Testing

Tested locally.

Risk

Minimal, hot reload isn't on by default.

Fixes #50190

Two separate issues:

1. When we process the EnC map, any tables after the last one that has an
update gets an "enc_recs" pointer that's one past the last row of the
table.  (the enc_recs pointer is used to speed up relative address lookup).  So
at lookup time if enc_recs says to look past the end of the EnC map table, we
know there won't be any updates - return -1.

2. When looking for the updated RVA of a method, we need to go through every
delta and find the latest one that has an update for the given method.  The
problem is that if a later generation doesn't have an update, we would take the
NULL return value at face value and it would look like the method had no
updates to its body - we would go back to using the original version from
before any updates were applied.  Instead now ignore lookup table misses and
remember the last successful lookup.  Fixes
dotnet#50190
@marek-safar marek-safar added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Mar 30, 2021
@mmitche
Copy link
Member

mmitche commented Mar 30, 2021

@marek-safar Is this ready for merge?

@marek-safar
Copy link
Contributor

marek-safar commented Mar 30, 2021

Is this ready for merge?

Yes

@Anipik Anipik merged commit f513229 into dotnet:release/6.0-preview3 Mar 30, 2021
@lambdageek lambdageek mentioned this pull request Apr 5, 2021
51 tasks
@ghost ghost locked as resolved and limited conversation to collaborators Apr 29, 2021
@lambdageek lambdageek deleted the fix-gh-50190-preview3 branch March 19, 2022 16:45
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Servicing-approved Approved for servicing release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants