Two small related fixes.

* A hidden undefined is not preemptable.
* It is always zero, so we don't need a dynamic reloc for it.

llvm-svn: 266424
diff --git a/lld/ELF/Symbols.cpp b/lld/ELF/Symbols.cpp
index 9fe73b1..fe0e01e 100644
--- a/lld/ELF/Symbols.cpp
+++ b/lld/ELF/Symbols.cpp
@@ -121,6 +121,9 @@
   if (isShared())
     return true;
 
+  if (getVisibility() != STV_DEFAULT)
+    return false;
+
   if (isUndefined()) {
     if (!isWeak())
       return true;
@@ -137,8 +140,6 @@
 
   if (!Config->Shared)
     return false;
-  if (getVisibility() != STV_DEFAULT)
-    return false;
   if (Config->Bsymbolic || (Config->BsymbolicFunctions && isFunc()))
     return false;
   return true;