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

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

Issue 12529008: Collect type feedback for fields. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 9 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_builder.h" 5 #include "vm/flow_graph_builder.h"
6 6
7 #include "lib/invocation_mirror.h" 7 #include "lib/invocation_mirror.h"
8 #include "vm/ast_printer.h" 8 #include "vm/ast_printer.h"
9 #include "vm/code_descriptors.h" 9 #include "vm/code_descriptors.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 2577 matching lines...) Expand 10 before | Expand all | Expand 10 after
2588 Append(for_value); 2588 Append(for_value);
2589 Value* store_value = for_value.value(); 2589 Value* store_value = for_value.value();
2590 if (FLAG_enable_type_checks) { 2590 if (FLAG_enable_type_checks) {
2591 const AbstractType& type = AbstractType::ZoneHandle(node->field().type()); 2591 const AbstractType& type = AbstractType::ZoneHandle(node->field().type());
2592 const String& dst_name = String::ZoneHandle(node->field().name()); 2592 const String& dst_name = String::ZoneHandle(node->field().name());
2593 store_value = BuildAssignableValue(node->value()->token_pos(), 2593 store_value = BuildAssignableValue(node->value()->token_pos(),
2594 store_value, 2594 store_value,
2595 type, 2595 type,
2596 dst_name); 2596 dst_name);
2597 } 2597 }
2598 StoreInstanceFieldInstr* store = new StoreInstanceFieldInstr( 2598 StoreInstanceFieldInstr* store = new StoreInstanceFieldInstr(
Kevin Millikin (Google) 2013/03/12 12:14:56 Thanks, I guess. But the dangling "(" is the real
Vyacheslav Egorov (Google) 2013/03/12 16:54:40 Done.
2599 node->field(), for_instance.value(), store_value, kEmitStoreBarrier); 2599 node->field(),
2600 for_instance.value(),
2601 store_value,
2602 kEmitStoreBarrier);
2600 ReturnDefinition(store); 2603 ReturnDefinition(store);
2601 } 2604 }
2602 2605
2603 2606
2604 // StoreInstanceFieldNode does not return result. 2607 // StoreInstanceFieldNode does not return result.
2605 void ValueGraphVisitor::VisitStoreInstanceFieldNode( 2608 void ValueGraphVisitor::VisitStoreInstanceFieldNode(
2606 StoreInstanceFieldNode* node) { 2609 StoreInstanceFieldNode* node) {
2607 UNIMPLEMENTED(); 2610 UNIMPLEMENTED();
2608 } 2611 }
2609 2612
(...skipping 689 matching lines...) Expand 10 before | Expand all | Expand 10 after
3299 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1; 3302 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1;
3300 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); 3303 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len);
3301 OS::SNPrint(chars, len, kFormat, function_name, reason); 3304 OS::SNPrint(chars, len, kFormat, function_name, reason);
3302 const Error& error = Error::Handle( 3305 const Error& error = Error::Handle(
3303 LanguageError::New(String::Handle(String::New(chars)))); 3306 LanguageError::New(String::Handle(String::New(chars))));
3304 Isolate::Current()->long_jump_base()->Jump(1, error); 3307 Isolate::Current()->long_jump_base()->Jump(1, error);
3305 } 3308 }
3306 3309
3307 3310
3308 } // namespace dart 3311 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698