diff options
author | Michael Kuperstein <michael.m.kuperstein@intel.com> | 2015-09-16 11:18:25 +0000 |
---|---|---|
committer | Michael Kuperstein <michael.m.kuperstein@intel.com> | 2015-09-16 11:18:25 +0000 |
commit | 098cd9fba73c25a23157049b19b16c84d39a0c6a (patch) | |
tree | 7ed96b63a159c2b36e3c72a11712d4a11f3636cd /llvm/lib/CodeGen/MachineInstr.cpp | |
parent | 11bb848ddcd632f13c5e8413bd452e9c064047dd (diff) | |
download | bcm5719-llvm-098cd9fba73c25a23157049b19b16c84d39a0c6a.tar.gz bcm5719-llvm-098cd9fba73c25a23157049b19b16c84d39a0c6a.zip |
[X86] Fix emitEpilogue() to make less assumptions about pops
This is the mirror image of r242395.
When X86FrameLowering::emitEpilogue() looks for where to insert the %esp addition that
deallocates stack space used for local allocations, it assumes that any sequence of pop
instructions from function exit backwards consists purely of restoring callee-save registers.
This may be false, since from some point backward, the pops may be clean-up of stack space
allocated for arguments to a call.
Patch by: amjad.aboud@intel.com
Differential Revision: http://reviews.llvm.org/D12688
llvm-svn: 247784
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstr.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineInstr.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp index 036965bf965..f2984b2ae0e 100644 --- a/llvm/lib/CodeGen/MachineInstr.cpp +++ b/llvm/lib/CodeGen/MachineInstr.cpp @@ -1735,13 +1735,16 @@ void MachineInstr::print(raw_ostream &OS, ModuleSlotTracker &MST, } bool HaveSemi = false; - const unsigned PrintableFlags = FrameSetup; + const unsigned PrintableFlags = FrameSetup | FrameDestroy; if (Flags & PrintableFlags) { if (!HaveSemi) OS << ";"; HaveSemi = true; OS << " flags: "; if (Flags & FrameSetup) OS << "FrameSetup"; + + if (Flags & FrameDestroy) + OS << "FrameDestroy"; } if (!memoperands_empty()) { |