summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeorge Rimar <grimar@accesssoftek.com>2018-12-03 14:44:02 +0000
committerGeorge Rimar <grimar@accesssoftek.com>2018-12-03 14:44:02 +0000
commit89230f7bc29946d534ee26f40472babebc3e4ed5 (patch)
tree156767876bd8b86472666ca7a7c8939b71da920b
parent1a6d6f053d80dcc7d772663fc8c4b36d8f3f0ef4 (diff)
downloadbcm5719-llvm-89230f7bc29946d534ee26f40472babebc3e4ed5.tar.gz
bcm5719-llvm-89230f7bc29946d534ee26f40472babebc3e4ed5.zip
[LLD][ELF] - Remove the excessive condition. NFC.
There is no need to check that In.DynSymTab != nullptr, because `includeInDynsym` already checks for `!Config->HasDynSymTab` and `HasDynSymTab` is the pre-condition for In.DynSymTab creation. llvm-svn: 348143
-rw-r--r--lld/ELF/Writer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp
index fb8d60ee80d..9d3dfb6f4a1 100644
--- a/lld/ELF/Writer.cpp
+++ b/lld/ELF/Writer.cpp
@@ -1661,7 +1661,7 @@ template <class ELFT> void Writer<ELFT>::finalizeSections() {
if (In.SymTab)
In.SymTab->addSymbol(Sym);
- if (In.DynSymTab && Sym->includeInDynsym()) {
+ if (Sym->includeInDynsym()) {
In.DynSymTab->addSymbol(Sym);
if (auto *File = dyn_cast_or_null<SharedFile<ELFT>>(Sym->File))
if (File->IsNeeded && !Sym->isUndefined())
OpenPOWER on IntegriCloud