Skip to content

[DestroyAddrHoisting] Skip init_enum_data_addrs. #81952

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
Jun 4, 2025

Conversation

nate-chandler
Copy link
Contributor

A destroy of an init_enum_data_addr is not equivalent to a destroy of the whole enum's address. Treat such destroys just like destroys of struct_element_addrs are treated: by bailing out.

rdar://152431332

moveonlywrapper_to_copyable_box changes the type so it's a type cast not
an identity cast.
The new function stripAccessAndAccessStorageCasts is analogous to the
existing function stripAccessAndIdentityCasts but differs in that the
latter uses isAccessStorageIdentityCast whereas the new function uses
isAccessStorageCast.
A destroy of an `init_enum_data_addr` is not equivalent to a destroy of
the whole enum's address.  Treat such destroys just like destroys of
`struct_element_addr`s are treated: by bailing out.

rdar://152431332
@nate-chandler
Copy link
Contributor Author

@swift-ci please test

@nate-chandler
Copy link
Contributor Author

@swift-ci please test source compatibility

@nate-chandler
Copy link
Contributor Author

@swift-ci please apple silicon benchmark

Copy link
Contributor

@meg-gupta meg-gupta left a comment

Choose a reason for hiding this comment

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

lgtm

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.

LGTM

@nate-chandler nate-chandler marked this pull request as ready for review June 4, 2025 02:39
@nate-chandler nate-chandler requested a review from jckarter as a code owner June 4, 2025 02:39
@nate-chandler nate-chandler enabled auto-merge June 4, 2025 02:39
@nate-chandler nate-chandler removed the request for review from jckarter June 4, 2025 02:39
@nate-chandler
Copy link
Contributor Author

@swift-ci please smoke test macos platform

@nate-chandler nate-chandler merged commit dd57d4d into swiftlang:main Jun 4, 2025
7 of 8 checks passed
@nate-chandler nate-chandler deleted the rdar152431332 branch June 4, 2025 17:34
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