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

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

Issue 101373006: Revert r31036, because of bit redness. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years 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.cc » ('j') | no next file with comments »
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 8
9 #include "vm/ast_printer.h" 9 #include "vm/ast_printer.h"
10 #include "vm/block_scheduler.h" 10 #include "vm/block_scheduler.h"
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 } 378 }
379 379
380 // Propagate types and eliminate more type tests. 380 // Propagate types and eliminate more type tests.
381 FlowGraphTypePropagator::Propagate(flow_graph); 381 FlowGraphTypePropagator::Propagate(flow_graph);
382 DEBUG_ASSERT(flow_graph->VerifyUseLists()); 382 DEBUG_ASSERT(flow_graph->VerifyUseLists());
383 383
384 // Use propagated class-ids to optimize further. 384 // Use propagated class-ids to optimize further.
385 optimizer.ApplyClassIds(); 385 optimizer.ApplyClassIds();
386 DEBUG_ASSERT(flow_graph->VerifyUseLists()); 386 DEBUG_ASSERT(flow_graph->VerifyUseLists());
387 387
388 // Propagate types for potentially newly added instructions by
389 // ApplyClassIds(). Must occur before canonicalization.
390 FlowGraphTypePropagator::Propagate(flow_graph);
391 DEBUG_ASSERT(flow_graph->VerifyUseLists());
392
393 // Do optimizations that depend on the propagated type information. 388 // Do optimizations that depend on the propagated type information.
394 if (optimizer.Canonicalize()) { 389 if (optimizer.Canonicalize()) {
395 // Invoke Canonicalize twice in order to fully canonicalize patterns 390 // Invoke Canonicalize twice in order to fully canonicalize patterns
396 // like "if (a & const == 0) { }". 391 // like "if (a & const == 0) { }".
397 optimizer.Canonicalize(); 392 optimizer.Canonicalize();
398 } 393 }
399 DEBUG_ASSERT(flow_graph->VerifyUseLists()); 394 DEBUG_ASSERT(flow_graph->VerifyUseLists());
400 395
401 BranchSimplifier::Simplify(flow_graph); 396 BranchSimplifier::Simplify(flow_graph);
402 DEBUG_ASSERT(flow_graph->VerifyUseLists()); 397 DEBUG_ASSERT(flow_graph->VerifyUseLists());
(...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after
963 Object::Handle(isolate->object_store()->sticky_error()); 958 Object::Handle(isolate->object_store()->sticky_error());
964 isolate->object_store()->clear_sticky_error(); 959 isolate->object_store()->clear_sticky_error();
965 isolate->set_long_jump_base(base); 960 isolate->set_long_jump_base(base);
966 return result.raw(); 961 return result.raw();
967 } 962 }
968 UNREACHABLE(); 963 UNREACHABLE();
969 return Object::null(); 964 return Object::null();
970 } 965 }
971 966
972 } // namespace dart 967 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/flow_graph_optimizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698