Skip to content

JIT: Handle async calls implemented via ldvirtftn properly #118726

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

Merged
merged 4 commits into from
Aug 15, 2025

Conversation

jakobbotsch
Copy link
Member

@jakobbotsch jakobbotsch commented Aug 14, 2025

Handling was missing to mark these as async and to insert async continuations.

Fix #118714

Handling was missing to mark these as async and to insert async
continuations.
@Copilot Copilot AI review requested due to automatic review settings August 14, 2025 13:15
@github-actions github-actions bot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Aug 14, 2025
Copy link
Contributor

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

Copy link
Contributor

@Copilot Copilot AI left a comment

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 adds proper async call handling for virtual method calls that are implemented via ldvirtftn in the JIT compiler. The changes ensure that these calls are correctly marked as async and have the necessary async continuation arguments inserted.

Key changes:

  • Extracts async call setup logic into reusable helper methods
  • Adds async handling for ldvirtftn-based virtual calls
  • Includes test infrastructure updates to enable async testing

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/coreclr/jit/importercalls.cpp Refactors async call handling into helper methods and adds async support for ldvirtftn calls
src/coreclr/jit/compiler.h Adds declarations for new async call helper methods
src/tests/async/Directory.Build.targets Enables async test builds by uncommenting DisableProjectBuild
src/tests/async/async-gvm/async-gvm.csproj Creates new test project for async generic virtual method testing
src/tests/async/async-gvm/async-gvm.cs Implements test cases for async generic virtual methods

@jakobbotsch
Copy link
Member Author

Opened #118735 to fix the failing test (flakey).

@jakobbotsch
Copy link
Member Author

All other failures are known, cc @dotnet/jit-contrib @VSadov PTAL @AndyAyersMS

Copy link
Member

@VSadov VSadov left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks!

@jakobbotsch jakobbotsch merged commit 4a55453 into dotnet:main Aug 15, 2025
109 of 113 checks passed
@jakobbotsch jakobbotsch deleted the fix-118714 branch August 15, 2025 06:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI runtime-async
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[RuntimeAsync] Possible issue with async GVMs
3 participants