Print variable's display name in dwarf DIE.
[oota-llvm.git] / lib / CodeGen / MachineSink.cpp
index a85a41fbaee8d92c9bc1b3656f36d2a7aa86071b..468bd01548c244dacfaa675c275d4116941cb90c 100644 (file)
@@ -212,6 +212,11 @@ bool MachineSinking::SinkInstruction(MachineInstr *MI, bool &SawStore) {
   // If there are no outputs, it must have side-effects.
   if (SuccToSinkTo == 0)
     return false;
+
+  // It's not safe to sink instructions to EH landing pad. Control flow into
+  // landing pad is implicitly defined.
+  if (SuccToSinkTo->isLandingPad())
+    return false;
   
   DEBUG(cerr << "Sink instr " << *MI);
   DEBUG(cerr << "to block " << *SuccToSinkTo);