Skip to content

[SILInliner] Added lexical lifetimes for arguments. #39495

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 2 commits into from
Sep 29, 2021

Conversation

nate-chandler
Copy link
Contributor

When the -enable-experimental-lexical-lifetimes flag is passed, added lexical borrow scopes for every non-trivial argument when inlining a function.

@nate-chandler
Copy link
Contributor Author

@swift-ci please test

Copy link
Contributor

@atrick atrick left a comment

Choose a reason for hiding this comment

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

Looks good

Previously, the SILInliner had a few lines of special-case code to
handle adding end_borrow instructions to the throw block corresponding
to a try_apply instruction.  Because there's a mechanism for tracking
all places where these end_borrows need to be inserted, just use that
mechanism rather than having a special case for the throw block.
When the -enable-experimental-lexical-lifetimes flag is passed, added
lexical borrow scopes for every non-trivial argument when inlining a
function.
@nate-chandler nate-chandler force-pushed the lexical_lifetimes/inliner branch from 820622a to 6bcbb04 Compare September 29, 2021 00:48
@nate-chandler
Copy link
Contributor Author

@swift-ci please test

@swift-ci
Copy link
Contributor

Build failed
Swift Test OS X Platform
Git Sha - 6bcbb04

@nate-chandler
Copy link
Contributor Author

@swift-ci please test macos platform

@nate-chandler nate-chandler merged commit 6163db1 into swiftlang:main Sep 29, 2021
@nate-chandler nate-chandler deleted the lexical_lifetimes/inliner branch September 29, 2021 19:44
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.

3 participants