add a missing else. This caused globals to be printed as:
authorChris Lattner <sabre@nondot.org>
Sun, 14 Jan 2007 06:08:14 +0000 (06:08 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 14 Jan 2007 06:08:14 +0000 (06:08 +0000)
       movq ___dso_handle@GOTPCREL(%rip)(%rip), %rsi

instead of:
        movq ___dso_handle@GOTPCREL(%rip), %rsi

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

lib/Target/X86/X86ATTAsmPrinter.cpp

index 1dfb43ae51329049f3c37c2b3d6f2dbc9693920a..1e60cd3f4d76c71574a201a858e709feba4f224c 100755 (executable)
@@ -310,7 +310,7 @@ void X86ATTAsmPrinter::printOperand(const MachineInstr *MI, unsigned OpNo,
           O << "@GOT";
         } else if (Subtarget->isPICStyleRIPRel()) {
           O << "@GOTPCREL(%rip)";
-        } if (Subtarget->is64Bit() && !NotRIPRel)
+        } else if (Subtarget->is64Bit() && !NotRIPRel)
             // Use rip when possible to reduce code size, except when
             // index or base register are also part of the address. e.g.
             // foo(%rip)(%rcx,%rax,4) is not legal