Skip to content

[6.0] Fix LifetimeDependenceDefUseWalker for address yields. #72768

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
Apr 9, 2024

Conversation

atrick
Copy link
Contributor

@atrick atrick commented Apr 2, 2024

Do not treat address yields as escapes.

--- CCC ---

Explanation: Fix LifetimeDependenceDefUseWalker for address yields.

Scope: Allows NonescapableTypes to be used with _modify accessors.

Radar/SR Issues: rdar://125752476 (UnsafeRawPointer property in non-escapable type doesn't compile)

Original PR: #72764

Risk: This fixes a latent bug in SIL utilities and verification. It reduces risk overall.

Testing: Unit tests added

Reviewer: TBD

@atrick atrick requested a review from meg-gupta April 2, 2024 15:42
@atrick atrick force-pushed the 60-fix-address-yield branch from a39bdc7 to 5459504 Compare April 2, 2024 15:45
@atrick
Copy link
Contributor Author

atrick commented Apr 2, 2024

@swift-ci test

@atrick atrick added the 🍒 release cherry pick Flag: Release branch cherry picks label Apr 4, 2024
@atrick atrick force-pushed the 60-fix-address-yield branch from 5459504 to 387730f Compare April 4, 2024 16:45
@atrick atrick force-pushed the 60-fix-address-yield branch from 387730f to cec8cf7 Compare April 9, 2024 05:33
@atrick atrick marked this pull request as ready for review April 9, 2024 05:42
@atrick atrick requested a review from a team as a code owner April 9, 2024 05:42
@atrick
Copy link
Contributor Author

atrick commented Apr 9, 2024

@swift-ci test

atrick added 4 commits April 9, 2024 08:53
These core utils did not handle UnconditionalCheckedCastAddrInst or
UncheckedRefCastAddrInst correctly.

(cherry picked from commit a1bb9f4)
It is not a SingleValueInstruction.

(cherry picked from commit 66dcf6a)
Do not treat address yields as escapes.

Fixes rdar://125752476 (`UnsafeRawPointer` property in non-escapable type doesn't compile)

(cherry picked from commit 1b6be74)
@atrick atrick force-pushed the 60-fix-address-yield branch from cec8cf7 to 0954b1b Compare April 9, 2024 15:53
@atrick
Copy link
Contributor Author

atrick commented Apr 9, 2024

@swift-ci test

@atrick atrick merged commit 8ea0787 into swiftlang:release/6.0 Apr 9, 2024
5 checks passed
@atrick atrick deleted the 60-fix-address-yield branch April 9, 2024 23:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍒 release cherry pick Flag: Release branch cherry picks swift 6.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants