| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <deque> | 5 #include <deque> |
| 6 #include <queue> | 6 #include <queue> |
| 7 | 7 |
| 8 #include "src/compiler/scheduler.h" | 8 #include "src/compiler/scheduler.h" |
| 9 | 9 |
| 10 #include "src/bit-vector.h" | 10 #include "src/bit-vector.h" |
| (...skipping 1193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1204 if (block->dominator_depth() > data->minimum_block_->dominator_depth()) { | 1204 if (block->dominator_depth() > data->minimum_block_->dominator_depth()) { |
| 1205 data->minimum_block_ = block; | 1205 data->minimum_block_ = block; |
| 1206 queue_.push(node); | 1206 queue_.push(node); |
| 1207 Trace("Propagating #%d:%s minimum_block = B%d, dominator_depth = %d\n", | 1207 Trace("Propagating #%d:%s minimum_block = B%d, dominator_depth = %d\n", |
| 1208 node->id(), node->op()->mnemonic(), | 1208 node->id(), node->op()->mnemonic(), |
| 1209 data->minimum_block_->id().ToInt(), | 1209 data->minimum_block_->id().ToInt(), |
| 1210 data->minimum_block_->dominator_depth()); | 1210 data->minimum_block_->dominator_depth()); |
| 1211 } | 1211 } |
| 1212 } | 1212 } |
| 1213 | 1213 |
| 1214 #if DEBUG | 1214 #if DCHECK_IS_ON |
| 1215 bool InsideSameDominatorChain(BasicBlock* b1, BasicBlock* b2) { | 1215 bool InsideSameDominatorChain(BasicBlock* b1, BasicBlock* b2) { |
| 1216 BasicBlock* dominator = scheduler_->GetCommonDominator(b1, b2); | 1216 BasicBlock* dominator = scheduler_->GetCommonDominator(b1, b2); |
| 1217 return dominator == b1 || dominator == b2; | 1217 return dominator == b1 || dominator == b2; |
| 1218 } | 1218 } |
| 1219 #endif | 1219 #endif |
| 1220 | 1220 |
| 1221 Scheduler* scheduler_; | 1221 Scheduler* scheduler_; |
| 1222 Schedule* schedule_; | 1222 Schedule* schedule_; |
| 1223 ZoneQueue<Node*> queue_; | 1223 ZoneQueue<Node*> queue_; |
| 1224 }; | 1224 }; |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1492 for (NodeVectorIter i = nodes->begin(); i != nodes->end(); ++i) { | 1492 for (NodeVectorIter i = nodes->begin(); i != nodes->end(); ++i) { |
| 1493 schedule_->SetBlockForNode(to, *i); | 1493 schedule_->SetBlockForNode(to, *i); |
| 1494 scheduled_nodes_[to->id().ToSize()].push_back(*i); | 1494 scheduled_nodes_[to->id().ToSize()].push_back(*i); |
| 1495 } | 1495 } |
| 1496 nodes->clear(); | 1496 nodes->clear(); |
| 1497 } | 1497 } |
| 1498 | 1498 |
| 1499 } // namespace compiler | 1499 } // namespace compiler |
| 1500 } // namespace internal | 1500 } // namespace internal |
| 1501 } // namespace v8 | 1501 } // namespace v8 |
| OLD | NEW |