Skip to content

Reset assignedInterval during verifyFinalAllocation - #49286

Merged
kunalspathak merged 3 commits into
dotnet:mainfrom
kunalspathak:lsra-fixes6
Mar 9, 2021
Merged

Reset assignedInterval during verifyFinalAllocation#49286
kunalspathak merged 3 commits into
dotnet:mainfrom
kunalspathak:lsra-fixes6

Conversation

@kunalspathak

Copy link
Copy Markdown
Contributor

My latest changes to EH Var for single defs exposed 2 more issues where we were not resetting the assignedInterval of a assigned reg:

  1. For RefTypeDef, if an interval doesn't get assigned to a new register, then reset the assignedInterval of the regRecord that is currently assigned to that interval.
  2. Again, for RefTypeDef, if an interval got assigned to a different register than the original assignReg of that interval and if that refposition is spilled immediately, then reset the assignedInterval of such regRecord.

Both of the above scenarios were exposed because they were EH Vars. In verifyFinalAllocation(), there are multiple places where we check for RefTypeDef and take action and I looked into consolidating all the logic at single place, but I was not sure if it will regress in the way we print the "Final allocation table". Hence, to honor the time, I went ahead and did the spot fixing of these 2 scenarios, but in future, will try to refactor various scenarios.

Fixes errors:

@ghostghost added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Mar 8, 2021
@kunalspathak

Copy link
Copy Markdown
ContributorAuthor

@dotnet/jit-contrib

@benaadams

Copy link
Copy Markdown
Member

Code formatting issue on Linux?

@kunalspathak

Copy link
Copy Markdown
ContributorAuthor

Code formatting issue on Linux?

Oh yes, fixed.

@kunalspathak
kunalspathak merged commit 3fc3a22 into dotnet:mainMar 9, 2021
@ghostghost locked as resolved and limited conversation to collaborators Apr 8, 2021
@JulieLeeMSFTJulieLeeMSFT added this to the 6.0.0 milestone Apr 15, 2021
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@kunalspathak@benaadams@AndyAyersMS@JulieLeeMSFT