[llvm-commits] CVS: llvm/lib/Target/SparcV9/SparcV9CodeEmitter.cpp

Chris Lattner lattner at cs.uiuc.edu
Mon Nov 22 13:42:52 PST 2004



Changes in directory llvm/lib/Target/SparcV9:

SparcV9CodeEmitter.cpp updated: 1.76 -> 1.77
---
Log message:

Remove some dead vars and some useless namespacification


---
Diffs of the changes:  (+1 -10)

Index: llvm/lib/Target/SparcV9/SparcV9CodeEmitter.cpp
diff -u llvm/lib/Target/SparcV9/SparcV9CodeEmitter.cpp:1.76 llvm/lib/Target/SparcV9/SparcV9CodeEmitter.cpp:1.77
--- llvm/lib/Target/SparcV9/SparcV9CodeEmitter.cpp:1.76	Mon Nov 22 15:25:10 2004
+++ llvm/lib/Target/SparcV9/SparcV9CodeEmitter.cpp	Mon Nov 22 15:42:40 2004
@@ -143,13 +143,8 @@
       rv = (CI->getRawValue() - MCE.getCurrentPCValue()) / 4;
     } else if (GlobalValue *GV = dyn_cast<GlobalValue>(V)) {
       unsigned Reloc;
-      bool isLocal = false;
       if (MI.getOpcode() == V9::CALL) {
         Reloc = V9::reloc_pcrel_call;
-#if 0   // FIXME: No need to emit stubs for internal functions.
-        if (!GV->hasExternalLinkage() && isa<Function>(GV))
-          isLocal = true;
-#endif
       } else if (MI.getOpcode() == V9::SETHI) {
         if (MO.isHiBits64())
           Reloc = V9::reloc_sethi_hh;
@@ -168,8 +163,7 @@
         assert(0 && "Unknown relocation!");
       }
 
-      MCE.addRelocation(MachineRelocation(MCE.getCurrentPCOffset(), Reloc, GV,
-                                          0, isLocal));
+      MCE.addRelocation(MachineRelocation(MCE.getCurrentPCOffset(), Reloc, GV));
       rv = 0;
     } else {
       std::cerr << "ERROR: PC relative disp unhandled:" << MO << "\n";
@@ -306,8 +300,5 @@
     }
 }
 
-
-namespace llvm {
 #include "SparcV9CodeEmitter.inc"
-} // End llvm namespace
 






More information about the llvm-commits mailing list