[llvm-bugs] [Bug 35666] New: Function aliases in .so not preserved when one is "copied" to executable
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Dec 14 15:21:07 PST 2017
https://bugs.llvm.org/show_bug.cgi?id=35666
Bug ID: 35666
Summary: Function aliases in .so not preserved when one is
"copied" to executable
Product: lld
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: ELF
Assignee: unassignedbugs at nondot.org
Reporter: rafael.espindola at gmail.com
CC: llvm-bugs at lists.llvm.org
This is an extremely low priority bug. Mostly just something I wanted to
document somewhere.
When a shared library has two aliased global symbols (foo=bar) and they are
objects, a copy relocation from an executable will bring both symbols to the
symbol table of the executable so that the alias is preserved.
If the symbols are functions that is not done. It is also not implemented by
bfd or gold.
The only way I can think of fixing this without bloating Symbol is to create a
single entry plt synthetic section and assign that to CopyRelSec, similar to
how we handle copy relocations.
This would have the advantage of removing NeedsPltAddr, but I think it would be
more complicated overall.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20171214/fd56460d/attachment.html>
More information about the llvm-bugs
mailing list