From ed2fc71610b722d450cda48e087b52a62c4624ef Mon Sep 17 00:00:00 2001 From: Evan Cheng Date: Fri, 9 Nov 2007 19:11:23 +0000 Subject: [PATCH] Unbreak x86-64 jumptable. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43955 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/X86ATTAsmPrinter.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/Target/X86/X86ATTAsmPrinter.cpp b/lib/Target/X86/X86ATTAsmPrinter.cpp index 07162115fa9..cee802d1650 100644 --- a/lib/Target/X86/X86ATTAsmPrinter.cpp +++ b/lib/Target/X86/X86ATTAsmPrinter.cpp @@ -506,7 +506,11 @@ void X86ATTAsmPrinter::printPICJumpTableSetLabel(unsigned uid, O << TAI->getSetDirective() << ' ' << TAI->getPrivateGlobalPrefix() << getFunctionNumber() << '_' << uid << "_set_" << MBB->getNumber() << ','; printBasicBlockLabel(MBB, false, false); - O << '-' << computePICLabel(getFunctionNumber(), TAI, Subtarget) << '\n'; + if (Subtarget->isPICStyleRIPRel()) + O << '-' << TAI->getPrivateGlobalPrefix() << "JTI" << getFunctionNumber() + << '_' << uid << '\n'; + else + O << '-' << computePICLabel(getFunctionNumber(), TAI, Subtarget) << '\n'; } void X86ATTAsmPrinter::printPICLabel(const MachineInstr *MI, unsigned Op) { -- 2.34.1