diff options
author | Jeffrey Yasskin <jyasskin@google.com> | 2010-03-22 16:13:21 +0000 |
---|---|---|
committer | Jeffrey Yasskin <jyasskin@google.com> | 2010-03-22 16:13:21 +0000 |
commit | 7d116ce2e3eaebd1a520d2e838db710473a456fa (patch) | |
tree | c7c8567516a7bf753509b4d212a3813f51caedf9 /llvm/lib/Target/ARM/Thumb1InstrInfo.cpp | |
parent | 53a47bf9018dbd59ec8bc7a8a5dbfc83879ca306 (diff) | |
download | bcm5719-llvm-7d116ce2e3eaebd1a520d2e838db710473a456fa.tar.gz bcm5719-llvm-7d116ce2e3eaebd1a520d2e838db710473a456fa.zip |
Don't leak a MachineInstruction from Thumb1InstrInfo::restoreCalleeSavedRegisters.
llvm-svn: 99182
Diffstat (limited to 'llvm/lib/Target/ARM/Thumb1InstrInfo.cpp')
-rw-r--r-- | llvm/lib/Target/ARM/Thumb1InstrInfo.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp b/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp index 29ae631269a..ad98839ce26 100644 --- a/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp +++ b/llvm/lib/Target/ARM/Thumb1InstrInfo.cpp @@ -200,6 +200,8 @@ restoreCalleeSavedRegisters(MachineBasicBlock &MBB, // It's illegal to emit pop instruction without operands. if (NumRegs) MBB.insert(MI, &*MIB); + else + MF.DeleteMachineInstr(MIB); return true; } |