| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 "src/compiler/instruction.h" | 5 #include "src/compiler/instruction.h" |
| 6 | 6 |
| 7 #include "src/compiler/common-operator.h" | 7 #include "src/compiler/common-operator.h" |
| 8 #include "src/compiler/generic-node-inl.h" | 8 #include "src/compiler/generic-node-inl.h" |
| 9 #include "src/compiler/graph.h" | 9 #include "src/compiler/graph.h" |
| 10 | 10 |
| (...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 it != schedule->rpo_order()->end(); ++it, ++rpo_number) { | 375 it != schedule->rpo_order()->end(); ++it, ++rpo_number) { |
| 376 DCHECK_EQ(NULL, (*blocks)[rpo_number]); | 376 DCHECK_EQ(NULL, (*blocks)[rpo_number]); |
| 377 DCHECK((*it)->GetRpoNumber().ToSize() == rpo_number); | 377 DCHECK((*it)->GetRpoNumber().ToSize() == rpo_number); |
| 378 (*blocks)[rpo_number] = new (zone) InstructionBlock(zone, *it); | 378 (*blocks)[rpo_number] = new (zone) InstructionBlock(zone, *it); |
| 379 } | 379 } |
| 380 } | 380 } |
| 381 | 381 |
| 382 | 382 |
| 383 InstructionSequence::InstructionSequence(Linkage* linkage, const Graph* graph, | 383 InstructionSequence::InstructionSequence(Linkage* linkage, const Graph* graph, |
| 384 const Schedule* schedule) | 384 const Schedule* schedule) |
| 385 : zone_(graph->zone()->isolate()), | 385 : zone_(schedule->zone()), |
| 386 node_count_(graph->NodeCount()), | 386 node_count_(graph->NodeCount()), |
| 387 node_map_(zone()->NewArray<int>(node_count_)), | 387 node_map_(zone()->NewArray<int>(node_count_)), |
| 388 instruction_blocks_(static_cast<int>(schedule->rpo_order()->size()), NULL, | 388 instruction_blocks_(static_cast<int>(schedule->rpo_order()->size()), NULL, |
| 389 zone()), | 389 zone()), |
| 390 linkage_(linkage), | 390 linkage_(linkage), |
| 391 constants_(ConstantMap::key_compare(), | 391 constants_(ConstantMap::key_compare(), |
| 392 ConstantMap::allocator_type(zone())), | 392 ConstantMap::allocator_type(zone())), |
| 393 immediates_(zone()), | 393 immediates_(zone()), |
| 394 instructions_(zone()), | 394 instructions_(zone()), |
| 395 next_virtual_register_(0), | 395 next_virtual_register_(0), |
| (...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 650 os << " B" << succ_block->id(); | 650 os << " B" << succ_block->id(); |
| 651 } | 651 } |
| 652 os << "\n"; | 652 os << "\n"; |
| 653 } | 653 } |
| 654 return os; | 654 return os; |
| 655 } | 655 } |
| 656 | 656 |
| 657 } // namespace compiler | 657 } // namespace compiler |
| 658 } // namespace internal | 658 } // namespace internal |
| 659 } // namespace v8 | 659 } // namespace v8 |
| OLD | NEW |