https://llvm.org/bugs/show_bug.cgi?id=31932
Bug ID: 31932 Summary: PIC references to __dso_handle should behave as with hidden visibility Product: clang Version: trunk Hardware: All OS: All Status: NEW Severity: normal Priority: P Component: LLVM Codegen Assignee: unassignedclangb...@nondot.org Reporter: rol...@hack.frob.com CC: llvm-bugs@lists.llvm.org, pho...@chromium.org Classification: Unclassified When Clang emits calls to __cxa_atexit, it generates references to the symbol __dso_handle. The sole purpose of this symbol is that it have a different address in each linked module (shared library or the executable). To that end, its definition is always made with hidden visibility. So using the GOT indirection table in PIC mode just adds extra indirection overhead and an extra dynamic reloc that will always be relaxed into a simple R_*_RELATIVE. GCC emits references to __dso_handle that do not use the GOT. I have a patch to fix this, though it might need some cleanup. -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs