Skip to content

MandatoryPerformanceOptimizations: prevent inlining of dynamic-self class methods #74657

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 1 commit into from
Jun 25, 2024

Conversation

eeckstein
Copy link
Contributor

@eeckstein eeckstein commented Jun 24, 2024

This fixes a compiler crash in embedded swift.
When a static/global variable is initialized with a class where the initializer uses dynamic Self the MandatoryPerformanceOptimizations crashed while trying to inline the initializer. Such initializer must not be inlined, because the caller (= the global-init function) cannot provide the dynamic-self metadata.

rdar://129241915

…lass methods

This fixes a compiler crash in embedded swift.

rdar://129241915
@eeckstein eeckstein requested a review from kubamracek June 24, 2024 13:02
@eeckstein
Copy link
Contributor Author

@swift-ci test

@eeckstein eeckstein merged commit 5bbf6d0 into swiftlang:main Jun 25, 2024
5 checks passed
@eeckstein eeckstein deleted the fix-mandatory-perf-opt branch June 25, 2024 05:24
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.

2 participants