summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-10-28 18:12:00 +0000
committerChris Lattner <sabre@nondot.org>2006-10-28 18:12:00 +0000
commit95e4786a7653abaa589cfc466969dbfe943b51d9 (patch)
tree1852cda8cf351f62fa391dddad3d6fa882513ba9 /include/llvm/CodeGen
parente7251a0377334bdb57bd188828bf89c9e3980fad (diff)
downloadllvm-95e4786a7653abaa589cfc466969dbfe943b51d9.tar.gz
llvm-95e4786a7653abaa589cfc466969dbfe943b51d9.tar.bz2
llvm-95e4786a7653abaa589cfc466969dbfe943b51d9.tar.xz
add a method for deleting dead jump tables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31268 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen')
-rw-r--r--include/llvm/CodeGen/MachineJumpTableInfo.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/llvm/CodeGen/MachineJumpTableInfo.h b/include/llvm/CodeGen/MachineJumpTableInfo.h
index adf33488c1..6f66707887 100644
--- a/include/llvm/CodeGen/MachineJumpTableInfo.h
+++ b/include/llvm/CodeGen/MachineJumpTableInfo.h
@@ -55,6 +55,12 @@ public:
return JumpTables;
}
+ /// RemoveJumpTable - Mark the specific index as being dead. This will cause
+ /// it to not be emitted.
+ void RemoveJumpTable(unsigned Idx) {
+ JumpTables[Idx].MBBs.clear();
+ }
+
/// ReplaceMBBInJumpTables - If Old is the target of any jump tables, update
/// the jump tables to branch to New instead.
bool ReplaceMBBInJumpTables(MachineBasicBlock *Old, MachineBasicBlock *New) {