Skip to content

IRGen: fix DLL storage for runtime functions #12353

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
Oct 10, 2017

Conversation

compnerd
Copy link
Member

@compnerd compnerd commented Oct 9, 2017

The runtime functions should not have DLLImport storage for the runtime
functions. Without this change, we would see swift_unexpectedError be
given DLL Import DLL Storage. It should probably be given DLLExport DLL
Storage. This is needed to repair the Windows build. The problem is
that the ExternalLinkage does not indicate whether the function is
internally available or externally available, merely that it
participates in linkage resolution. Ensure that we only give import
storage to declarations with ExternalLinkage.

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

Resolves SR-NNNN.

The runtime functions should not have DLLImport storage for the runtime
functions.  Without this change, we would see `swift_unexpectedError` be
given DLL Import DLL Storage.  It should probably be given DLLExport DLL
Storage.  This is needed to repair the Windows build.  The problem is
that the ExternalLinkage does not indicate whether the function is
internally available or externally available, merely that it
participates in linkage resolution.  Ensure that we only give import
storage to declarations with ExternalLinkage.
@compnerd
Copy link
Member Author

compnerd commented Oct 9, 2017

@swift-ci please test and merge

@compnerd
Copy link
Member Author

@swift-ci please clean test Linux platform

@swift-ci
Copy link
Contributor

Build failed
Swift Test Linux Platform
Git Sha - 15011f0

@compnerd
Copy link
Member Author

Please test with following pull request:
swiftlang/swift-corelibs-libdispatch#308

@swift-ci Please test Linux platform

@compnerd
Copy link
Member Author

This change doesn't actually depend on the lib dispatch change. Going to merge this.

@compnerd compnerd merged commit 4df3541 into swiftlang:master Oct 10, 2017
@compnerd compnerd deleted the dll-storage branch October 10, 2017 15:46
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