Skip to content

[interp] Fix compile failures causing silent fallback to JIT - #119775

Merged
kg merged 2 commits into
dotnet:mainfrom
kg:interp-fallback-fix
Sep 17, 2025
Merged

kg merged 2 commits into
dotnet:mainfrom
kg:interp-fallback-fix

Conversation

@kg

@kg kg commented Sep 16, 2025

Copy link
Copy Markdown
Contributor

baseservices\invalid_operations\InvalidOperations is currently failing downstream of its actual failure - the actual failure is that the interpreter doesn't support the type of calli the test is doing, but right now when we fail compilation as a result of this we silently retry with the JIT.

It seems like the intended behavior is that if we configure a method to be interpreted and it fails due to BADCODE or NO_WAY, we want to fail-fast instead of falling back to JIT. Not sure this is the right solution though.

@janvorli Is this the kind of fix you had in mind? I didn't find a better way to do it but you might have some ideas.

@dotnet-policy-service

Copy link
Copy Markdown
Contributor

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

@kg
kg force-pushed the interp-fallback-fix branch from f00bfaf to 3aaf14d Compare September 16, 2025 20:02
@kg
kg marked this pull request as ready for review September 16, 2025 20:02
Copilot AI review requested due to automatic review settings September 16, 2025 20:02

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 fixes a silent fallback issue in the interpreter where compilation failures were being masked as CORJIT_SKIPPED, causing tests to fall back to JIT compilation instead of properly reporting interpreter failures.

  • Removes silent fallback behavior when interpreter compilation fails
  • Ensures interpreter compilation failures are properly propagated instead of being converted to CORJIT_SKIPPED

@janvorli

Copy link
Copy Markdown
Member

@kg yes, that's what I've meant. The baseservices\invalid_operations\InvalidOperations test with your change now reports

System.InvalidProgramException: Common Language Runtime detected an invalid program.

Which I guess is the expected effect.

@kg
kg merged commit 0ed71cd into dotnet:main Sep 17, 2025
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 18, 2025
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.

3 participants