diff options
author | Tanya Lattner <tonic@nondot.org> | 2009-09-16 01:04:02 +0000 |
---|---|---|
committer | Tanya Lattner <tonic@nondot.org> | 2009-09-16 01:04:02 +0000 |
commit | 08b3db33e1a5cdfcfe2bfb01838bc6331bf8cffb (patch) | |
tree | 451f5fd850ff580daace266f75691c32f091ca4d | |
parent | b5f7f4fe8d427268e8319a9eab306ff2e58c326d (diff) | |
download | llvm-08b3db33e1a5cdfcfe2bfb01838bc6331bf8cffb.tar.gz |
Merge 80960 from mainline.
If we've pushed registers onto the stack, but aren't adjusting the stack pointer
(i.e., there are no local variables and stuff), we still need to output FDE
information for the pushed registers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_26@81973 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/X86/X86RegisterInfo.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Target/X86/X86RegisterInfo.cpp b/lib/Target/X86/X86RegisterInfo.cpp index 112ff1ce24de..f922a84c0562 100644 --- a/lib/Target/X86/X86RegisterInfo.cpp +++ b/lib/Target/X86/X86RegisterInfo.cpp @@ -1086,12 +1086,12 @@ void X86RegisterInfo::emitPrologue(MachineFunction &MF) const { emitSPUpdate(MBB, MBBI, StackPtr, -(int64_t)NumBytes, Is64Bit, TII); } - if (NumBytes && needsFrameMoves) { + if ((NumBytes || PushedRegs) && needsFrameMoves) { // Mark end of stack pointer adjustment. unsigned LabelId = MMI->NextLabelID(); BuildMI(MBB, MBBI, DL, TII.get(X86::DBG_LABEL)).addImm(LabelId); - if (!HasFP) { + if (!HasFP && NumBytes) { // Define the current CFA rule to use the provided offset. if (StackSize) { MachineLocation SPDst(MachineLocation::VirtualFP); |