}
-InstructionSequence::InstructionSequence(Linkage* linkage, const Graph* graph,
+InstructionSequence::InstructionSequence(Zone* instruction_zone,
+ Linkage* linkage, const Graph* graph,
const Schedule* schedule)
- : zone_(schedule->zone()),
+ : zone_(instruction_zone),
node_count_(graph->NodeCount()),
node_map_(zone()->NewArray<int>(node_count_)),
instruction_blocks_(static_cast<int>(schedule->rpo_order()->size()), NULL,
// TODO(titzer): s/IsDouble/IsFloat64/
class InstructionSequence FINAL {
public:
- InstructionSequence(Linkage* linkage, const Graph* graph,
+ InstructionSequence(Zone* zone, Linkage* linkage, const Graph* graph,
const Schedule* schedule);
int NextVirtualRegister() { return next_virtual_register_++; }
profiler_data = BasicBlockInstrumentor::Instrument(info_, graph, schedule);
}
- InstructionSequence sequence(linkage, graph, schedule);
+ Zone* instruction_zone = schedule->zone();
+ InstructionSequence sequence(instruction_zone, linkage, graph, schedule);
// Select and schedule instructions covering the scheduled graph.
{
// Initialize the codegen and generate code.
Linkage* linkage = new (scope_->main_zone()) Linkage(&info);
- code = new v8::internal::compiler::InstructionSequence(linkage, graph,
- schedule);
+ code = new v8::internal::compiler::InstructionSequence(
+ scope_->main_zone(), linkage, graph, schedule);
SourcePositionTable source_positions(graph);
InstructionSelector selector(code, schedule, &source_positions);
selector.SelectInstructions();
Scheduler::ComputeSpecialRPO(&schedule);
DCHECK(schedule.rpo_order()->size() > 0);
}
- code = new TestInstrSeq(&linkage, &graph, &schedule);
+ code = new TestInstrSeq(main_zone(), &linkage, &graph, &schedule);
}
Node* Int32Constant(int32_t val) {
int initial_node_count = graph()->NodeCount();
CompilationInfo info(test_->isolate(), test_->zone());
Linkage linkage(&info, call_descriptor());
- InstructionSequence sequence(&linkage, graph(), schedule);
+ InstructionSequence sequence(test_->zone(), &linkage, graph(), schedule);
SourcePositionTable source_position_table(graph());
InstructionSelector selector(&sequence, schedule, &source_position_table,
features);