COFF: Do not handle __NULL_IMPORT_DESCRIPTOR differently than the other symbols.
__NULL_IMPORT_DESCRIPTOR is a symbol used by MSVC liner to construct
the import descriptor table. We do not use the symbol. Previously,
we had code to skip that symbol. That code does not actually do
anything meaningful because no one is referencing the symbol, the
symbol would naturally be ignored. This patch stops recognizing
the symbol.
llvm-svn: 245280
diff --git a/lld/COFF/InputFiles.cpp b/lld/COFF/InputFiles.cpp
index 5da40d0..7ef496b 100644
--- a/lld/COFF/InputFiles.cpp
+++ b/lld/COFF/InputFiles.cpp
@@ -63,13 +63,8 @@
LazySymbols.reserve(NumSyms);
// Read the symbol table to construct Lazy objects.
- uint32_t I = 0;
- for (const Archive::Symbol &Sym : File->symbols()) {
- auto *B = new (&Buf[I++]) Lazy(this, Sym);
- // Skip special symbol exists in import library files.
- if (B->getName() != "__NULL_IMPORT_DESCRIPTOR")
- LazySymbols.push_back(B);
- }
+ for (const Archive::Symbol &Sym : File->symbols())
+ LazySymbols.push_back(new (Buf++) Lazy(this, Sym));
// Seen is a map from member files to boolean values. Initially
// all members are mapped to false, which indicates all these files