Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(432)

Side by Side Diff: src/compiler/scheduler.cc

Issue 602643002: Improve memory usage in Turbofan. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler/schedule.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/compiler/graph.h" 10 #include "src/compiler/graph.h"
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 schedule_root_nodes_(zone), 232 schedule_root_nodes_(zone),
233 node_data_(graph_->NodeCount(), DefaultSchedulerData(), zone), 233 node_data_(graph_->NodeCount(), DefaultSchedulerData(), zone),
234 has_floating_control_(false) {} 234 has_floating_control_(false) {}
235 235
236 236
237 Schedule* Scheduler::ComputeSchedule(Graph* graph) { 237 Schedule* Scheduler::ComputeSchedule(Graph* graph) {
238 Schedule* schedule; 238 Schedule* schedule;
239 bool had_floating_control = false; 239 bool had_floating_control = false;
240 do { 240 do {
241 Zone tmp_zone(graph->zone()->isolate()); 241 Zone tmp_zone(graph->zone()->isolate());
242 schedule = new (graph->zone()) Schedule(graph->zone()); 242 schedule = new (graph->zone())
243 Schedule(graph->zone(), static_cast<size_t>(graph->NodeCount()));
243 Scheduler scheduler(&tmp_zone, graph, schedule); 244 Scheduler scheduler(&tmp_zone, graph, schedule);
244 245
245 scheduler.BuildCFG(); 246 scheduler.BuildCFG();
246 247
247 Scheduler::ComputeSpecialRPO(schedule); 248 Scheduler::ComputeSpecialRPO(schedule);
248 scheduler.GenerateImmediateDominatorTree(); 249 scheduler.GenerateImmediateDominatorTree();
249 250
250 scheduler.PrepareUses(); 251 scheduler.PrepareUses();
251 scheduler.ScheduleEarly(); 252 scheduler.ScheduleEarly();
252 scheduler.ScheduleLate(); 253 scheduler.ScheduleLate();
(...skipping 863 matching lines...) Expand 10 before | Expand all | Expand 10 after
1116 1117
1117 #if DEBUG 1118 #if DEBUG
1118 if (FLAG_trace_turbo_scheduler) PrintRPO(num_loops, loops, final_order); 1119 if (FLAG_trace_turbo_scheduler) PrintRPO(num_loops, loops, final_order);
1119 VerifySpecialRPO(num_loops, loops, final_order); 1120 VerifySpecialRPO(num_loops, loops, final_order);
1120 #endif 1121 #endif
1121 return final_order; 1122 return final_order;
1122 } 1123 }
1123 } 1124 }
1124 } 1125 }
1125 } // namespace v8::internal::compiler 1126 } // namespace v8::internal::compiler
OLDNEW
« no previous file with comments | « src/compiler/schedule.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698