Skip to content

LLVM exports too many symbols (on Unix like systems like Linux and Mac) #19707

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

Open
llvmbot opened this issue Apr 4, 2014 · 2 comments
Open
Assignees
Labels
bugzilla Issues migrated from bugzilla cmake Build system in general and CMake in particular

Comments

@llvmbot
Copy link
Member

llvmbot commented Apr 4, 2014

Bugzilla Link 19333
Version trunk
OS All
Reporter LLVM Bugzilla Contributor
CC @tstellar

Extended Description

This doesn't apply to Windows because by default symbols are hidden in DLLs. On Unix like systems like Linux and Mac though there are a bunch of symbols exported that shouldn't be which increase startup time. There is a long and annoying process of marking symbols to export for the libraries but for the executables (which obviously shouldn't export any symbols unless they have a plugin system) the flag -fvisibility=hidden should be a cheap and easy optimization. Note that LLVM does not use runtime type information or exceptions so I believe there shouldn't be very many problems however, according to http://gcc.gnu.org/wiki/Visibility there also some other cases (for example, static data members of templates that can cause this problem). Using #pragma push for one's own code could be one way of quickly accomplishing this.

@llvmbot
Copy link
Member Author

llvmbot commented Apr 4, 2014

assigned to @tstellar

@tstellar
Copy link
Collaborator

This patch may help: https://reviews.llvm.org/D54439

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla cmake Build system in general and CMake in particular
Projects
None yet
Development

No branches or pull requests

2 participants