[llvm-commits] CVS: llvm/lib/Target/X86/X86ATTAsmPrinter.cpp

Evan Cheng evan.cheng at apple.com
Mon Jun 4 11:55:37 PDT 2007



Changes in directory llvm/lib/Target/X86:

X86ATTAsmPrinter.cpp updated: 1.105 -> 1.106
---
Log message:

Misuse of hasExternalLinkage(), should be checking isDeclaration().

---
Diffs of the changes:  (+2 -2)

 X86ATTAsmPrinter.cpp |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)


Index: llvm/lib/Target/X86/X86ATTAsmPrinter.cpp
diff -u llvm/lib/Target/X86/X86ATTAsmPrinter.cpp:1.105 llvm/lib/Target/X86/X86ATTAsmPrinter.cpp:1.106
--- llvm/lib/Target/X86/X86ATTAsmPrinter.cpp:1.105	Sat May  5 04:04:50 2007
+++ llvm/lib/Target/X86/X86ATTAsmPrinter.cpp	Mon Jun  4 13:54:57 2007
@@ -286,7 +286,7 @@
     }
 
     if (printStub(TM, Subtarget)) {
-      // Link-once, External, or Weakly-linked global variables need
+      // Link-once, declaration, or Weakly-linked global variables need
       // non-lazily-resolved stubs
       if (GV->isDeclaration() ||
           GV->hasWeakLinkage() ||
@@ -351,7 +351,7 @@
         else
           O << "@GOTOFF";
       } else if (Subtarget->isPICStyleRIPRel() && !NotRIPRel) {
-        if ((GV->hasExternalLinkage() ||
+        if ((GV->isDeclaration() ||
              GV->hasWeakLinkage() ||
              GV->hasLinkOnceLinkage()) &&
             TM.getRelocationModel() != Reloc::Static)






More information about the llvm-commits mailing list