summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
diff options
context:
space:
mode:
authorMatt Arsenault <Matthew.Arsenault@amd.com>2016-06-21 23:01:17 +0000
committerMatt Arsenault <Matthew.Arsenault@amd.com>2016-06-21 23:01:17 +0000
commit6b3e2120b9edc34a9bc7df1753f3e44b9ff1c2c5 (patch)
treebdc7b0711f5a1d4ea09347d96350e6783031ea9d /llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
parenta783bac50bf7ab18aedeea9df60ecff7d8054942 (diff)
downloadbcm5719-llvm-6b3e2120b9edc34a9bc7df1753f3e44b9ff1c2c5.tar.gz
bcm5719-llvm-6b3e2120b9edc34a9bc7df1753f3e44b9ff1c2c5.zip
Make DeadMachineInstructionElim preserve CFG
llvm-svn: 273330
Diffstat (limited to 'llvm/lib/CodeGen/DeadMachineInstructionElim.cpp')
-rw-r--r--llvm/lib/CodeGen/DeadMachineInstructionElim.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp b/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
index ae58b5bb0e7..0b8dc7a86ad 100644
--- a/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
+++ b/llvm/lib/CodeGen/DeadMachineInstructionElim.cpp
@@ -42,6 +42,11 @@ namespace {
initializeDeadMachineInstructionElimPass(*PassRegistry::getPassRegistry());
}
+ void getAnalysisUsage(AnalysisUsage &AU) const override {
+ AU.setPreservesCFG();
+ MachineFunctionPass::getAnalysisUsage(AU);
+ }
+
private:
bool isDead(const MachineInstr *MI) const;
};
OpenPOWER on IntegriCloud