[llvm-commits] [llvm] r42749 - /llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp

Dan Gohman djg at cray.com
Mon Oct 8 08:12:17 PDT 2007


Author: djg
Date: Mon Oct  8 10:12:17 2007
New Revision: 42749

URL: http://llvm.org/viewvc/llvm-project?rev=42749&view=rev
Log:
In -debug mode, dump SelectionDAGs both before and after the
optimization passes.

Modified:
    llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp

Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp?rev=42749&r1=42748&r2=42749&view=diff

==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp Mon Oct  8 10:12:17 2007
@@ -4624,10 +4624,13 @@
 }
 
 void SelectionDAGISel::CodeGenAndEmitDAG(SelectionDAG &DAG) {
+  DOUT << "Lowered selection DAG:\n";
+  DEBUG(DAG.dump());
+
   // Run the DAG combiner in pre-legalize mode.
   DAG.Combine(false, *AA);
   
-  DOUT << "Lowered selection DAG:\n";
+  DOUT << "Optimized lowered selection DAG:\n";
   DEBUG(DAG.dump());
   
   // Second step, hack on the DAG until it only uses operations and types that
@@ -4640,6 +4643,9 @@
   // Run the DAG combiner in post-legalize mode.
   DAG.Combine(true, *AA);
   
+  DOUT << "Optimized legalized selection DAG:\n";
+  DEBUG(DAG.dump());
+
   if (ViewISelDAGs) DAG.viewGraph();
 
   // Third, instruction select all of the operations to machine code, adding the





More information about the llvm-commits mailing list