[TargetMachine] Drop special case for *-win32-macho
authorFangrui Song <i@maskray.me>
Sat, 21 Aug 2021 20:59:17 +0000 (13:59 -0700)
committerFangrui Song <i@maskray.me>
Sat, 21 Aug 2021 20:59:17 +0000 (13:59 -0700)
clang CodeGenModule shouldAssumeDSOLocal has set dso_local.

llvm/lib/Target/TargetMachine.cpp

index 86cb30d..32bdb71 100644 (file)
@@ -140,12 +140,6 @@ bool TargetMachine::shouldAssumeDSOLocal(const Module &M,
   }
 
   if (TT.isOSBinFormatMachO()) {
-    // Make an exception for windows OS in the triple: Some firmware builds use
-    // *-win32-macho triples. This (accidentally?) produced windows relocations
-    // without GOT tables in older clang versions; Keep this behaviour.
-    if (TT.isOSWindows())
-      return true;
-
     if (RM == Reloc::Static)
       return true;
     return GV->isStrongDefinitionForLinker();