r360841 introduced CommonSymbol class. An unintended behavioral change
introduced by that change was that common symbols are not internalized
by LTO under some condition, as reported in
https://bugs.llvm.org/show_bug.cgi?id=41978.
This patch fixes that issue.
The issue occurred under the following condition:
- There exists a common symbol
- At least one DSO is given to lld
If the above conditions are met, Symbol::includeInDynsym() returned a
wrong value for a common symbol.
llvm-mc -filetype=obj -triple=x86_64-unknown-linux /dev/null -o %t.so.o
/dev/null has been used in many other tests.