aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/StrongPHIElimination.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2009-12-17 23:42:32 +0000
committerBill Wendling <isanbard@gmail.com>2009-12-17 23:42:32 +0000
commit3de8249078354d25b37b40e0f10b4f88226d3dd4 (patch)
tree788b5f0e3b4fefa0fe20c47902cb51228c8c7127 /lib/CodeGen/StrongPHIElimination.cpp
parent08ce53996e944927699dd6e98839deb9d9d4c092 (diff)
Turn off critical edge splitting for landing pads. The introduction of a
non-landing pad basic block as the successor to a block that ends in an unconditional jump will cause block folding to remove the added block as a successor. Thus eventually removing it AND the landing pad entirely. Critical edge splitting is an optimization, so we can safely turn it off when dealing with landing pads. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91634 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/StrongPHIElimination.cpp')
-rw-r--r--lib/CodeGen/StrongPHIElimination.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/StrongPHIElimination.cpp b/lib/CodeGen/StrongPHIElimination.cpp
index 3c139068e6..345e22835e 100644
--- a/lib/CodeGen/StrongPHIElimination.cpp
+++ b/lib/CodeGen/StrongPHIElimination.cpp
@@ -907,7 +907,7 @@ bool StrongPHIElimination::runOnMachineFunction(MachineFunction &Fn) {
// Determine which phi node operands need copies
for (MachineFunction::iterator I = Fn.begin(), E = Fn.end(); I != E; ++I)
- if (!I->empty() &&
+ if (!I->empty() && !I->isLandingPad() &&
I->begin()->getOpcode() == TargetInstrInfo::PHI)
processBlock(I);