forked from OSchip/llvm-project
Teach reginfo how to deal with ADJSTACKPTRri, allowing us to generate:
add %ESP, 20 jmp %EDX # TAIL CALL instead of: add %ESP, -8 add %ESP, 28 jmp %EDX # TAIL CALL llvm-svn: 22047
This commit is contained in:
parent
dd66a41e0e
commit
97e3b65652
|
@ -544,6 +544,9 @@ void X86RegisterInfo::emitEpilogue(MachineFunction &MF,
|
|||
PI->getOperand(0).getReg() == X86::ESP) {
|
||||
NumBytes -= PI->getOperand(1).getImmedValue();
|
||||
MBB.erase(PI);
|
||||
} else if (PI->getOpcode() == X86::ADJSTACKPTRri) {
|
||||
NumBytes += PI->getOperand(1).getImmedValue();
|
||||
MBB.erase(PI);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue