diff options
author | Shoaib Meenai <smeenai@fb.com> | 2022-02-01 23:59:50 -0800 |
---|---|---|
committer | Shoaib Meenai <smeenai@fb.com> | 2022-02-04 18:09:37 -0800 |
commit | 997f2a56dea16a8b0a8827ca00cbaa21fbcd2338 (patch) | |
tree | 2f0d60e40efe6aeed93c50bac86b8ca2841f63d2 /llvm/lib/Transforms/Utils/LCSSA.cpp | |
parent | 34de63c37fa968048cc09cb46371fd8a3bef0c4d (diff) | |
download | llvm-997f2a56dea16a8b0a8827ca00cbaa21fbcd2338.zip llvm-997f2a56dea16a8b0a8827ca00cbaa21fbcd2338.tar.gz llvm-997f2a56dea16a8b0a8827ca00cbaa21fbcd2338.tar.bz2 |
[ELF] Avoid wrapping unreferenced lazy symbols
There's a couple of motivations here:
* LLD 12 (which I was originally testing with) was adding an undefined
symbol to the symbol table if you attempted to wrap an unreferenced
lazy symbol, which would later break `--no-allow-shlib-undefined`. LLD
on main actually produces a weak undefined symbol, so this doesn't
break anyway, but it's cleaner to not have the weak undefined symbol
as well. The new behavior also matches bfd and gold.
* PROVIDE in a linker script referencing a wrapped symbol would think
that an otherwise-unreferenced lazy symbol which was wrapped was
actually referenced, and therefore proceed with the definition, which
goes against expectations. The new behavior also matches bfd and gold.
Reviewed By: MaskRay
Differential Revision: https://reviews.llvm.org/D118756
Diffstat (limited to 'llvm/lib/Transforms/Utils/LCSSA.cpp')
0 files changed, 0 insertions, 0 deletions