Revert the part of 45849 that treated weak globals
authorDale Johannesen <dalej@apple.com>
Thu, 17 Jan 2008 23:36:04 +0000 (23:36 +0000)
committerDale Johannesen <dalej@apple.com>
Thu, 17 Jan 2008 23:36:04 +0000 (23:36 +0000)
as weak globals rather than commons.  While not wrong,
this change tickled a latent bug in Darwin's strip,
so revert it for now as a workaround.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46147 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/ARM/ARMAsmPrinter.cpp

index 4cea34271e5e49474821225ca8508c0f876c9cf9..416084adce2c5e3603e0fad22bd509b98dfd257e 100644 (file)
@@ -845,9 +845,8 @@ bool ARMAsmPrinter::doFinalization(Module &M) {
         }
       }
 
-      if (I->hasInternalLinkage() || 
-           (!Subtarget->isTargetDarwin() && 
-            (I->hasWeakLinkage() || I->hasLinkOnceLinkage()))) {
+      if (I->hasInternalLinkage() || I->hasWeakLinkage() ||
+          I->hasLinkOnceLinkage()) {
         if (Size == 0) Size = 1;   // .comm Foo, 0 is undefined, avoid it.
         if (!NoZerosInBSS && TAI->getBSSSection())
           SwitchToDataSection(TAI->getBSSSection(), I);