[ELF] Remove redundant !isPreemptible in Symbol::computeBinding()
authorFangrui Song <maskray@google.com>
Sun, 11 Aug 2019 16:12:07 +0000 (16:12 +0000)
committerFangrui Song <maskray@google.com>
Sun, 11 Aug 2019 16:12:07 +0000 (16:12 +0000)
commit635eda8bb0fde5eae101f98586146125dbbf550c
treefa71560c0070502863bafcbd2a968a07dcc346f9
parente812bf5530872e4b33c8f205da81acccc2a41413
[ELF] Remove redundant !isPreemptible in Symbol::computeBinding()

!isPreemptible was added in r343668 to fix PR39104: symbols redefined by
replaceWithDefined() might be incorrectly considered STB_LOCAL if a
version script specified `local: *;`.

After r367869 (`config->defaultSymbolVersion` was removed), we will
assign VER_NDX_LOCAL to only regular Defined and CommonSymbol, not
Defined created by replaceWithDefined() (because scanVersionScript() is
called before scanRelocations()). The !isPreemptible is thus redundant
and can be deleted.

llvm-svn: 368535
lld/ELF/Symbols.cpp