Skip to content

JIT: Avoid overriding argument register with 'jmp' epilog - #114899

Merged
jakobbotsch merged 1 commit into
dotnet:mainfrom
jakobbotsch:jump-pop-ecx
Apr 23, 2025
Merged

JIT: Avoid overriding argument register with 'jmp' epilog#114899
jakobbotsch merged 1 commit into
dotnet:mainfrom
jakobbotsch:jump-pop-ecx

Conversation

@jakobbotsch

Copy link
Copy Markdown
Member

Porting a change from #114861 with a few minor diffs

Copilot AI review requested due to automatic review settings April 22, 2025 09:35
@ghost ghost added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Apr 22, 2025

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the JIT epilog logic to prevent overriding the argument register when a jmp operation is used, porting a change from PR #114861.

  • The condition in genFnEpilog now checks that compJmpOpUsed is false before proceeding.
  • This change ensures the "pop ecx" instruction is only executed when it’s safe to do so.

Comment thread src/coreclr/jit/codegenxarch.cpp
@dotnet-policy-service

Copy link
Copy Markdown
Contributor

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

@jakobbotsch

Copy link
Copy Markdown
Member Author

PTAL @dotnet/jit-contrib

A few minor diffs in tests for CEE_JMP.

@jakobbotsch
jakobbotsch requested a review from a team April 22, 2025 23:06
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-CodeGen-coreclr CLR 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.

3 participants