summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MachineScheduler.cpp
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2013-04-30 22:10:59 +0000
committerAndrew Trick <atrick@apple.com>2013-04-30 22:10:59 +0000
commitdd77014acc05c77052934596063aa911e18fdbcb (patch)
tree7b85640880ef4ee1c7bb1b110ba482bcbbfd3416 /llvm/lib/CodeGen/MachineScheduler.cpp
parent8d285ada3dd509b81abd481e83fd4c307b801037 (diff)
downloadbcm5719-llvm-dd77014acc05c77052934596063aa911e18fdbcb.tar.gz
bcm5719-llvm-dd77014acc05c77052934596063aa911e18fdbcb.zip
MI Sched: revert a minor heuristic that snuck in with -misched-vcopy.
I'll fix the heuristic in a general way in a follow-up commit. llvm-svn: 180815
Diffstat (limited to 'llvm/lib/CodeGen/MachineScheduler.cpp')
-rw-r--r--llvm/lib/CodeGen/MachineScheduler.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/MachineScheduler.cpp b/llvm/lib/CodeGen/MachineScheduler.cpp
index 32aedbee946..fff6b2b4c06 100644
--- a/llvm/lib/CodeGen/MachineScheduler.cpp
+++ b/llvm/lib/CodeGen/MachineScheduler.cpp
@@ -1990,9 +1990,15 @@ void ConvergingScheduler::tryCandidate(SchedCandidate &Cand,
return;
// Weak edges are for clustering and other constraints.
+ //
+ // Deferring TryCand here does not change Cand's reason. This is good in the
+ // sense that a bad candidate shouldn't affect a previous candidate's
+ // goodness, but bad in that it is assymetric and depends on queue order.
+ CandReason OrigReason = Cand.Reason;
if (tryLess(getWeakLeft(TryCand.SU, Zone.isTop()),
getWeakLeft(Cand.SU, Zone.isTop()),
TryCand, Cand, Weak)) {
+ Cand.Reason = OrigReason;
return;
}
// Avoid critical resource consumption and balance the schedule.
OpenPOWER on IntegriCloud