[llvm-commits] [llvm] r59759 - in /llvm/trunk/lib/CodeGen/SelectionDAG: ScheduleDAGFast.cpp ScheduleDAGRRList.cpp

Dan Gohman gohman at apple.com
Thu Nov 20 16:10:42 PST 2008


Author: djg
Date: Thu Nov 20 18:10:42 2008
New Revision: 59759

URL: http://llvm.org/viewvc/llvm-project?rev=59759&view=rev
Log:
Change these schedulers to not emit no-ops. It turns out that
the RR scheduler actually does look at latency values, but it
doesn't use a hazard recognizer so it has no way to know when
a no-op is needed, as opposed to just stalling and incrementing
the cycle count.

Modified:
    llvm/trunk/lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp
    llvm/trunk/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp

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

==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/ScheduleDAGFast.cpp Thu Nov 20 18:10:42 2008
@@ -577,9 +577,7 @@
     }
     NotReady.clear();
 
-    if (!CurSU)
-      Sequence.push_back(0);
-    else
+    if (CurSU)
       ScheduleNodeBottomUp(CurSU, CurCycle);
     ++CurCycle;
   }

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

==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp Thu Nov 20 18:10:42 2008
@@ -1052,9 +1052,7 @@
     }
     NotReady.clear();
 
-    if (!CurSU)
-      Sequence.push_back(0);
-    else
+    if (CurSU)
       ScheduleNodeBottomUp(CurSU, CurCycle);
     ++CurCycle;
   }
@@ -1152,9 +1150,7 @@
     AvailableQueue->push_all(NotReady);
     NotReady.clear();
 
-    if (!CurSU)
-      Sequence.push_back(0);
-    else
+    if (CurSU)
       ScheduleNodeTopDown(CurSU, CurCycle);
     ++CurCycle;
   }





More information about the llvm-commits mailing list