If we have to reset the calculation of the compact encoding, then also reset the
authorBill Wendling <isanbard@gmail.com>
Fri, 11 Nov 2011 00:59:14 +0000 (00:59 +0000)
committerBill Wendling <isanbard@gmail.com>
Fri, 11 Nov 2011 00:59:14 +0000 (00:59 +0000)
"saved register" index.
<rdar://problem/10430076>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144350 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/X86FrameLowering.cpp

index ece90cb1ca7305a602ec506143b9066d397ac4b5..819d24203b2b8cf06f234f1c1ed1a32d503a081c 100644 (file)
@@ -518,6 +518,7 @@ uint32_t X86FrameLowering::getCompactUnwindEncoding(MachineFunction &MF) const {
 
       CFAOffset = 0;
       memset(SavedRegs, 0, sizeof(SavedRegs));
+      SavedRegIdx = 6;
       InstrOffset += MoveInstrSize;
     } else if (Opc == SubtractInstr) {
       if (StackAdjust)