Skip to content

[Async CC] Add remaining fields to context. #34471

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

Conversation

nate-chandler
Copy link
Contributor

A few fields either from the initial specification or from the declaration in Task.h had not yet been added to the layout of an async context. Here, those remaining field are here added. Specifically, the following fields are now part of the layout.

  • AsyncContextFlags Flags
  • TaskContinuationFunction * __ptrauth(...) yieldToCaller?
  • TaskContinuationFunction * __ptrauth(...) resumeFromYield?
  • TaskContinuationFunction * __ptrauth(...) abortFromYield?
  • ExecutorRef calleeActorDuringYield?
  • YieldTypes yieldValues...

Filtered code for adding ResumeParent to the async layout through the
new lambda.
Filtered code for adding ResumeParentExecutor to the async layout
through the new lambda.
The following fields are now available when the function is a coroutine:
- TaskContinuationFunction * __ptrauth(...) yieldToCaller?
- TaskContinuationFunction * __ptrauth(...) resumeFromYield?
- TaskContinuationFunction * __ptrauth(...) abortFromYield?
- ExecutorRef calleeActorDuringYield?
- YieldTypes yieldValues...

These fields have yet to be filled in.

The following field are now available when the function is NOT a
coroutine (whereas previously they were always available):
- ResultTypes directResults...
@nate-chandler
Copy link
Contributor Author

@swift-ci please test

@nate-chandler nate-chandler merged commit e27ebf5 into swiftlang:main Oct 28, 2020
@nate-chandler nate-chandler deleted the concurrency/irgen/remaining-context-fields branch October 28, 2020 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant