Skip to content

IRGen: address TODO for Windows static linking #41516

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
Feb 24, 2022

Conversation

compnerd
Copy link
Member

This improves the static linking story on Windows by wiring up
information about the static vs dynamic build of the module into the
code generation for references to module external symbols. We now can
indicate a module external symbol to be known local if it is expected to
be internalized due to static linking. Even though the symbol may not
be defined in the same module, the definition will be provided locally
at link time. This avoids needing to resolve a dllimport'ed symbol to a
local symbol at link time.

Replace this paragraph with a description of your changes and rationale. Provide links to external references/discussions if appropriate.

Resolves SR-NNNN.

This improves the static linking story on Windows by wiring up
information about the static vs dynamic build of the module into the
code generation for references to module external symbols.  We now can
indicate a module external symbol to be known local if it is expected to
be internalized due to static linking.  Even though the symbol may not
be defined in the same module, the definition will be provided locally
at link time.  This avoids needing to resolve a dllimport'ed symbol to a
local symbol at link time.
@compnerd
Copy link
Member Author

CC: @aschwaighofer

@compnerd
Copy link
Member Author

@swift-ci please test

Copy link
Contributor

@aschwaighofer aschwaighofer left a comment

Choose a reason for hiding this comment

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

lgtm

@compnerd compnerd merged commit 48de949 into swiftlang:main Feb 24, 2022
@compnerd compnerd deleted the remote-is-local branch February 24, 2022 16:31
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