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

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

Issue 10541069: Add more intrinsics, enable new compiler's optimized mode for ia32. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 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
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/flow_graph_optimizer.h" 5 #include "vm/flow_graph_optimizer.h"
6 6
7 #include "vm/flow_graph_builder.h" 7 #include "vm/flow_graph_builder.h"
8 #include "vm/il_printer.h" 8 #include "vm/il_printer.h"
9 #include "vm/object_store.h" 9 #include "vm/object_store.h"
10 10
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 } 86 }
87 87
88 88
89 static bool HasOneDouble(const ICData& ic_data) { 89 static bool HasOneDouble(const ICData& ic_data) {
90 const Class& double_class = 90 const Class& double_class =
91 Class::Handle(Isolate::Current()->object_store()->double_class()); 91 Class::Handle(Isolate::Current()->object_store()->double_class());
92 return ICDataHasReceiverClass(ic_data, double_class); 92 return ICDataHasReceiverClass(ic_data, double_class);
93 } 93 }
94 94
95 95
96
97 void FlowGraphOptimizer::TryReplaceWithBinaryOp(InstanceCallComp* comp, 96 void FlowGraphOptimizer::TryReplaceWithBinaryOp(InstanceCallComp* comp,
98 Token::Kind op_kind) { 97 Token::Kind op_kind) {
99 if (comp->ic_data()->NumberOfChecks() != 1) { 98 if (comp->ic_data()->NumberOfChecks() != 1) {
100 // TODO(srdjan): Not yet supported. 99 // TODO(srdjan): Not yet supported.
101 return; 100 return;
102 } 101 }
103 if (!HasTwoSmi(*comp->ic_data())) { 102 if (!HasTwoSmi(*comp->ic_data())) {
104 // TODO(srdjan): Not yet supported. 103 // TODO(srdjan): Not yet supported.
105 return; 104 return;
106 } 105 }
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 instr->computation()->Accept(this); 299 instr->computation()->Accept(this);
301 } 300 }
302 301
303 302
304 void FlowGraphOptimizer::VisitBind(BindInstr* instr) { 303 void FlowGraphOptimizer::VisitBind(BindInstr* instr) {
305 instr->computation()->Accept(this); 304 instr->computation()->Accept(this);
306 } 305 }
307 306
308 307
309 } // namespace dart 308 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698