aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnton Korobeynikov <asl@math.spbu.ru>2009-07-16 14:16:45 +0000
committerAnton Korobeynikov <asl@math.spbu.ru>2009-07-16 14:16:45 +0000
commite1c9aabd7776a2be0f4bacce393731ecf3d07cf5 (patch)
treeabd1b56e81ee449a1123630f10ba165e2c05d849
parent9b812b0131d3912155f6720e731ccf7d87118276 (diff)
downloadexternal_llvm-e1c9aabd7776a2be0f4bacce393731ecf3d07cf5.zip
external_llvm-e1c9aabd7776a2be0f4bacce393731ecf3d07cf5.tar.gz
external_llvm-e1c9aabd7776a2be0f4bacce393731ecf3d07cf5.tar.bz2
Missed part of prev. patch
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76008 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Target/SystemZ/SystemZRegisterInfo.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Target/SystemZ/SystemZRegisterInfo.cpp b/lib/Target/SystemZ/SystemZRegisterInfo.cpp
index dfd5336..95daf7b 100644
--- a/lib/Target/SystemZ/SystemZRegisterInfo.cpp
+++ b/lib/Target/SystemZ/SystemZRegisterInfo.cpp
@@ -261,10 +261,12 @@ void SystemZRegisterInfo::emitEpilogue(MachineFunction &MF,
// During callee-saved restores emission stack frame was not yet finialized
// (and thus - the stack size was unknown). Tune the offset having full stack
// size in hands.
- if (SystemZMFI->getCalleeSavedFrameSize()) {
+ if (StackSize || MFI->hasCalls()) {
assert((MBBI->getOpcode() == SystemZ::MOV64rmm ||
MBBI->getOpcode() == SystemZ::MOV64rm) &&
"Expected to see callee-save register restore code");
+ assert(MF.getRegInfo().isPhysRegUsed(SystemZ::R15D) &&
+ "Invalid stack frame calculation!");
unsigned i = 0;
MachineInstr &MI = *MBBI;