aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineInstr.cpp
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2012-06-05 21:44:23 +0000
committerAndrew Trick <atrick@apple.com>2012-06-05 21:44:23 +0000
commit4b037005d26e4de08cbbb6a015c6531fe179da78 (patch)
tree16bff1e7c92b688d4e3212066c7b139d9cded202 /llvm/lib/CodeGen/MachineInstr.cpp
parent8ae50eb4a6c44f25e82571a5b7015d0ab1075393 (diff)
downloadllvm-4b037005d26e4de08cbbb6a015c6531fe179da78.zip
llvm-4b037005d26e4de08cbbb6a015c6531fe179da78.tar.gz
llvm-4b037005d26e4de08cbbb6a015c6531fe179da78.tar.bz2
MachineInstr::eraseFromParent fix for removing bundled instrs.
Patch by Ivan Llopard. llvm-svn: 158025
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstr.cpp')
-rw-r--r--llvm/lib/CodeGen/MachineInstr.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp
index 2dfb299..a35978b 100644
--- a/llvm/lib/CodeGen/MachineInstr.cpp
+++ b/llvm/lib/CodeGen/MachineInstr.cpp
@@ -872,7 +872,8 @@ void MachineInstr::eraseFromParent() {
MBB->erase(MI);
}
}
- getParent()->erase(this);
+ // Erase the individual instruction, which may itself be inside a bundle.
+ getParent()->erase_instr(this);
}