[llvm-commits] [llvm] r46167 - in /llvm/branches/release_22/lib/Target: PowerPC/PPCAsmPrinter.cpp X86/X86AsmPrinter.cpp
Tanya Lattner
tonic at nondot.org
Fri Jan 18 11:13:34 PST 2008
Author: tbrethou
Date: Fri Jan 18 13:13:34 2008
New Revision: 46167
URL: http://llvm.org/viewvc/llvm-project?rev=46167&view=rev
Log:
Merge from mainline.
Revert the part of 45848 that treated weak globals
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.
Modified:
llvm/branches/release_22/lib/Target/PowerPC/PPCAsmPrinter.cpp
llvm/branches/release_22/lib/Target/X86/X86AsmPrinter.cpp
Modified: llvm/branches/release_22/lib/Target/PowerPC/PPCAsmPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_22/lib/Target/PowerPC/PPCAsmPrinter.cpp?rev=46167&r1=46166&r2=46167&view=diff
==============================================================================
--- llvm/branches/release_22/lib/Target/PowerPC/PPCAsmPrinter.cpp (original)
+++ llvm/branches/release_22/lib/Target/PowerPC/PPCAsmPrinter.cpp Fri Jan 18 13:13:34 2008
@@ -917,7 +917,8 @@
if (C->isNullValue() && /* FIXME: Verify correct */
!I->hasSection() &&
- (I->hasInternalLinkage() || I->hasExternalLinkage())) {
+ (I->hasInternalLinkage() || I->hasWeakLinkage() ||
+ I->hasLinkOnceLinkage() || I->hasExternalLinkage())) {
if (Size == 0) Size = 1; // .comm Foo, 0 is undefined, avoid it.
if (I->hasExternalLinkage()) {
O << "\t.globl " << name << '\n';
Modified: llvm/branches/release_22/lib/Target/X86/X86AsmPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_22/lib/Target/X86/X86AsmPrinter.cpp?rev=46167&r1=46166&r2=46167&view=diff
==============================================================================
--- llvm/branches/release_22/lib/Target/X86/X86AsmPrinter.cpp (original)
+++ llvm/branches/release_22/lib/Target/X86/X86AsmPrinter.cpp Fri Jan 18 13:13:34 2008
@@ -181,9 +181,8 @@
}
if (!I->isThreadLocal() &&
- (I->hasInternalLinkage() ||
- (!Subtarget->isTargetDarwin() &&
- (I->hasWeakLinkage() || I->hasLinkOnceLinkage())))) {
+ (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);
More information about the llvm-commits
mailing list