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

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

Issue 17977002: - Remove arguments definition test from the VM. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 5 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 | « runtime/vm/flow_graph_inliner.cc ('k') | runtime/vm/flow_graph_type_propagator.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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/flow_graph_optimizer.h" 5 #include "vm/flow_graph_optimizer.h"
6 6
7 #include "vm/bit_vector.h" 7 #include "vm/bit_vector.h"
8 #include "vm/cha.h" 8 #include "vm/cha.h"
9 #include "vm/flow_graph_builder.h" 9 #include "vm/flow_graph_builder.h"
10 #include "vm/flow_graph_compiler.h" 10 #include "vm/flow_graph_compiler.h"
(...skipping 5540 matching lines...) Expand 10 before | Expand all | Expand 10 after
5551 const Object& value = instr->value()->definition()->constant_value(); 5551 const Object& value = instr->value()->definition()->constant_value();
5552 if (IsNonConstant(value)) { 5552 if (IsNonConstant(value)) {
5553 SetValue(instr, non_constant_); 5553 SetValue(instr, non_constant_);
5554 } else if (IsConstant(value)) { 5554 } else if (IsConstant(value)) {
5555 // TODO(kmillikin): Handle assertion. 5555 // TODO(kmillikin): Handle assertion.
5556 SetValue(instr, non_constant_); 5556 SetValue(instr, non_constant_);
5557 } 5557 }
5558 } 5558 }
5559 5559
5560 5560
5561 void ConstantPropagator::VisitArgumentDefinitionTest(
5562 ArgumentDefinitionTestInstr* instr) {
5563 SetValue(instr, non_constant_);
5564 }
5565
5566
5567 void ConstantPropagator::VisitCurrentContext(CurrentContextInstr* instr) { 5561 void ConstantPropagator::VisitCurrentContext(CurrentContextInstr* instr) {
5568 SetValue(instr, non_constant_); 5562 SetValue(instr, non_constant_);
5569 } 5563 }
5570 5564
5571 5565
5572 void ConstantPropagator::VisitClosureCall(ClosureCallInstr* instr) { 5566 void ConstantPropagator::VisitClosureCall(ClosureCallInstr* instr) {
5573 SetValue(instr, non_constant_); 5567 SetValue(instr, non_constant_);
5574 } 5568 }
5575 5569
5576 5570
(...skipping 1558 matching lines...) Expand 10 before | Expand all | Expand 10 after
7135 7129
7136 // Insert materializations at environment uses. 7130 // Insert materializations at environment uses.
7137 const Class& cls = Class::Handle(alloc->constructor().Owner()); 7131 const Class& cls = Class::Handle(alloc->constructor().Owner());
7138 for (intptr_t i = 0; i < exits.length(); i++) { 7132 for (intptr_t i = 0; i < exits.length(); i++) {
7139 CreateMaterializationAt(exits[i], alloc, cls, *fields); 7133 CreateMaterializationAt(exits[i], alloc, cls, *fields);
7140 } 7134 }
7141 } 7135 }
7142 7136
7143 7137
7144 } // namespace dart 7138 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_inliner.cc ('k') | runtime/vm/flow_graph_type_propagator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698