-
Notifications
You must be signed in to change notification settings - Fork 10.5k
build: hide symbols using CMake #31953
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
Conversation
This uses the CMake settings to correctly select the visibility attribute for the runtime.
@edymtt - I think that this is a better approach to what you were trying to do. I'd still like to understand how this is a performance thing. These are not weak symbols, they are COMDATed symbols. However both of those do not incur a penalty - the weak symbol just means that if one is not provided it will be used, but the resolution is done once at load time. |
@swift-ci please test |
CC: @drexin |
Build failed |
Build failed |
@compnerd This came from an internal verifier which says that weak symbols can impact app launch time. I'm not completely clear as to why, but I guess |
@mikeash Yes, that’s absolutely correct, the original statement of the reason just made it seem like the change caused a regression at runtime. Eric helped clear that up. Just a miscommunication on the actual results of the change. |
@compnerd Yeah, it's always a bit tricky and weird when internal stuff bubbles up like this. Glad we're all on the same page now. |
@swift-ci please test |
@edymtt Ill go ahead and merge this, and then follow up with the tests for ensuring that this doesn't happen again in the future. Thanks for the help! |
This uses the CMake settings to correctly select the visibility
attribute for the runtime.
Addresses rdar://63454568