From 1d885c0ede4b384559a82ebb437341d8b5cb11e2 Mon Sep 17 00:00:00 2001 From: Evan Cheng Date: Sat, 30 Jan 2010 01:16:15 +0000 Subject: [PATCH] Don't forget to transfer target flag when inserting a tailcall instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@94872 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/X86/X86RegisterInfo.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/Target/X86/X86RegisterInfo.cpp b/lib/Target/X86/X86RegisterInfo.cpp index e32891de7f0..903ba72af07 100644 --- a/lib/Target/X86/X86RegisterInfo.cpp +++ b/lib/Target/X86/X86RegisterInfo.cpp @@ -1244,7 +1244,8 @@ void X86RegisterInfo::emitEpilogue(MachineFunction &MF, // Jump to label or value in register. if (RetOpcode == X86::TCRETURNdi|| RetOpcode == X86::TCRETURNdi64) BuildMI(MBB, MBBI, DL, TII.get(X86::TAILJMPd)). - addGlobalAddress(JumpTarget.getGlobal(), JumpTarget.getOffset()); + addGlobalAddress(JumpTarget.getGlobal(), JumpTarget.getOffset(), + JumpTarget.getTargetFlags()); else if (RetOpcode== X86::TCRETURNri64) BuildMI(MBB, MBBI, DL, TII.get(X86::TAILJMPr64), JumpTarget.getReg()); else