[lld] aedc81b - [ELF] Remove unneeded sym->inDynamicList check
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 8 09:17:43 PST 2024
Author: Fangrui Song
Date: 2024-12-08T09:17:38-08:00
New Revision: aedc81b9d8880a60877a53469aeb89ff62466f6f
URL: https://github.com/llvm/llvm-project/commit/aedc81b9d8880a60877a53469aeb89ff62466f6f
DIFF: https://github.com/llvm/llvm-project/commit/aedc81b9d8880a60877a53469aeb89ff62466f6f.diff
LOG: [ELF] Remove unneeded sym->inDynamicList check
Follow-up to d31fb264821ceac90b55c87c3f777053ab30a9af
Added:
Modified:
lld/ELF/LTO.cpp
Removed:
################################################################################
diff --git a/lld/ELF/LTO.cpp b/lld/ELF/LTO.cpp
index 5ed69c8c3befa7..3973c0546b340f 100644
--- a/lld/ELF/LTO.cpp
+++ b/lld/ELF/LTO.cpp
@@ -254,9 +254,8 @@ void BitcodeCompiler::add(BitcodeFile &f) {
usedStartStop.count(objSym.getSectionName());
// Identify symbols exported dynamically, and that therefore could be
// referenced by a shared library not visible to the linker.
- r.ExportDynamic =
- sym->computeBinding(ctx) != STB_LOCAL &&
- (ctx.arg.exportDynamic || sym->exportDynamic || sym->inDynamicList);
+ r.ExportDynamic = sym->computeBinding(ctx) != STB_LOCAL &&
+ (ctx.arg.exportDynamic || sym->exportDynamic);
const auto *dr = dyn_cast<Defined>(sym);
r.FinalDefinitionInLinkageUnit =
(isExec || sym->visibility() != STV_DEFAULT) && dr &&
More information about the llvm-commits
mailing list