- Fix SelectionDAG to generate correct CFGs.
- Add a basic machine-level dead block eliminator.

These two have to go together, since many other parts of the code generator are unable to handle the unreachable blocks otherwise created.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54333 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/TargetMachine.cpp b/lib/Target/TargetMachine.cpp
index 600a120..2916763 100644
--- a/lib/Target/TargetMachine.cpp
+++ b/lib/Target/TargetMachine.cpp
@@ -40,6 +40,7 @@
   bool RealignStack;
   bool VerboseAsm;
   bool DisableJumpTables;
+  bool DisableCorrectBranchFolding;
 }
 
 static cl::opt<bool, true> PrintCode("print-machineinstrs",
@@ -163,6 +164,11 @@
            cl::location(DisableJumpTables),
            cl::init(false));
 
+static cl::opt<bool, true>
+DisableCorrectISelFolding(cl::Hidden, "disable-correct-folding",
+cl::desc("Do not perform correct branch folding in the instruction selector."),
+cl::location(DisableCorrectBranchFolding), cl::init(false));
+
 //---------------------------------------------------------------------------
 // TargetMachine Class
 //