add machinery to remove unecessary dynamic symbols at link time#222
add machinery to remove unecessary dynamic symbols at link time#222ezra-varady wants to merge 3 commits intolanterndata:mainfrom
Conversation
scripts/build_symbol_suppression.sh
Outdated
|
|
||
| # build version script | ||
| # this script will place everything except undefined symbols and | ||
| echo "LANTERN { |
There was a problem hiding this comment.
What is the significance of "LANTERN" here? is it the version name? the section name in the linker script?
There was a problem hiding this comment.
It's the version name, I wasn't sure if it made sense to use a specific version
8ba2121 to
31e2e3a
Compare
|
It seems the reason for namespace I changed the version name to |
This attempts to address #202. It adds a cmake target for an
ldversion script that places all symbols not explicitly marked withPGDLL_EXPORTin thelocalsection. It finds the functions that need to be marked as global automatically so it shouldn't require developers to mark their functions in a suppression script. I believe that--version-scriptshould behave the same way inlldthough there isn't any documentation so this may only work with gnu tools. I would have preferred to set all visibility to hidden then manually mark functions to be exported in source since this is more transparent to developers, however libstdc++ doesn't allow thisexample symbol exports with suppression script
EDIT: apparently Darwin uses its own linker so this isn't compatible with osx builds. Since this will be a relatively small percentage of deployments long term I think it's acceptable to just export more symbols on mac
EDIT2: sanitizer failure is unrelated to changes. It passed on the previous run, seems there's some minor non-determinism in the index that fails in that test