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

Side by Side Diff: runtime/vm/compiler.cc

Issue 10960014: Implement range analysis for smi values. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: cleanup Created 8 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 | « no previous file | runtime/vm/flow_graph_optimizer.h » ('j') | runtime/vm/flow_graph_optimizer.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/compiler.h" 5 #include "vm/compiler.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 #include "vm/ast_printer.h" 8 #include "vm/ast_printer.h"
9 #include "vm/code_generator.h" 9 #include "vm/code_generator.h"
10 #include "vm/code_patcher.h" 10 #include "vm/code_patcher.h"
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 198
199 // Unbox doubles. 199 // Unbox doubles.
200 flow_graph->ComputeUseLists(); 200 flow_graph->ComputeUseLists();
201 optimizer.SelectRepresentations(); 201 optimizer.SelectRepresentations();
202 202
203 if (FLAG_cp || FLAG_cse) flow_graph->ComputeUseLists(); 203 if (FLAG_cp || FLAG_cse) flow_graph->ComputeUseLists();
204 if (FLAG_cp) ConstantPropagator::Optimize(flow_graph); 204 if (FLAG_cp) ConstantPropagator::Optimize(flow_graph);
205 if (FLAG_cse) DominatorBasedCSE::Optimize(flow_graph); 205 if (FLAG_cse) DominatorBasedCSE::Optimize(flow_graph);
206 if (FLAG_licm) LICM::Optimize(flow_graph); 206 if (FLAG_licm) LICM::Optimize(flow_graph);
207 207
208 // TODO(vegorov): move optimistic smis unboxing into Sminess propagator.
Florian Schneider 2012/09/21 08:56:44 I don't understand this TODO. Can you make it clea
Vyacheslav Egorov (Google) 2012/09/21 20:08:07 Done.
209 optimizer.InferSmiRanges();
210
208 // Perform register allocation on the SSA graph. 211 // Perform register allocation on the SSA graph.
209 FlowGraphAllocator allocator(*flow_graph); 212 FlowGraphAllocator allocator(*flow_graph);
210 allocator.AllocateRegisters(); 213 allocator.AllocateRegisters();
211 214
212 if (FLAG_print_flow_graph) { 215 if (FLAG_print_flow_graph) {
213 OS::Print("After Optimizations:\n"); 216 OS::Print("After Optimizations:\n");
214 FlowGraphPrinter printer(*flow_graph); 217 FlowGraphPrinter printer(*flow_graph);
215 printer.PrintBlocks(); 218 printer.PrintBlocks();
216 } 219 }
217 } 220 }
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after
562 result = isolate->object_store()->sticky_error(); 565 result = isolate->object_store()->sticky_error();
563 isolate->object_store()->clear_sticky_error(); 566 isolate->object_store()->clear_sticky_error();
564 isolate->set_long_jump_base(base); 567 isolate->set_long_jump_base(base);
565 return result.raw(); 568 return result.raw();
566 } 569 }
567 UNREACHABLE(); 570 UNREACHABLE();
568 return Object::null(); 571 return Object::null();
569 } 572 }
570 573
571 } // namespace dart 574 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/flow_graph_optimizer.h » ('j') | runtime/vm/flow_graph_optimizer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698