Skip to content

Conversation

VSadov
Copy link
Member

@VSadov VSadov commented Apr 18, 2025

This is to keep track of the changes done to address PR feedback in dotnet/runtime#114675

@VSadov VSadov added the area-async Runtime generate async state machines label Apr 18, 2025
@VSadov VSadov changed the title [RuntimeAsync] Feedback form the merging PR in the runtime repo. [RuntimeAsync] Feedback from the merging PR in the runtime repo. Apr 22, 2025
@VSadov
Copy link
Member Author

VSadov commented Apr 22, 2025

I think it is time to merge this as we need to update to the latest API shape (i.e. AsyncHelpers)

@VSadov VSadov requested a review from jakobbotsch April 22, 2025 22:20

SoftwareExceptionFrame exceptionFrame;
#ifdef TARGET_X86
_ASSERTE(!"Introduce `IL_ThrowExact_x86` following the pattern of other Throw helpers.");
Copy link
Member

Choose a reason for hiding this comment

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

Does it mean the EH test fails on x86 now? Can we disable it somehow?

Copy link
Member Author

Choose a reason for hiding this comment

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

x86 does not do FEATURE_EH_FUNCLETS right now so it will work. Thus we can postpone introducing IL_ThrowExact_x86.

When x86 is moved onto FEATURE_EH_FUNCLETS plan, which I understand will happen at some point, we can remove HELPER_METHOD_FRAME_BEGIN_ATTRIB_NOPOLL path, which is desirable, but will also need to implement IL_ThrowExact_x86. It takes an extra parameter, I have only vague idea why.

Copy link
Member Author

@VSadov VSadov Apr 23, 2025

Choose a reason for hiding this comment

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

All runtime tests should be passing right now, including async and including EH - that is on win-x64 and win-x86, where it is easy to test once in a while.

Copy link
Member

Choose a reason for hiding this comment

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

When x86 is moved onto FEATURE_EH_FUNCLETS plan, which I understand will happen at some point,

It is expected to happen very soon. The changes are in dotnet/runtime#113576. The last remaining item before this gets enabled is private diagnostic tests run. If you would like to get ahead of this, you can apply the 10 line change locally and do the required fixes to make things work.

Copy link
Member

Choose a reason for hiding this comment

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

Context about last testing item: dotnet/runtime#113985 (comment).

Copy link
Member

@filipnavara filipnavara Apr 24, 2025

Choose a reason for hiding this comment

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

It takes an extra parameter, I have only vague idea why.

win-x86 doesn't have unwinding information for native code. Thus we need to capture the precise register context in assembly code before giving control to the C code since we cannot run VirtualUnwind to get it.

This should be fairly mechanical change so I can make a PR for the code.

Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Member

@jakobbotsch jakobbotsch left a comment

Choose a reason for hiding this comment

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

LGTM

@VSadov
Copy link
Member Author

VSadov commented Apr 23, 2025

Thanks!

@VSadov VSadov merged commit 281ac4b into dotnet:feature/async2-experiment Apr 23, 2025
1 of 7 checks passed
@VSadov VSadov deleted the feedback branch April 23, 2025 00:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-async Runtime generate async state machines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants