| OLD | NEW |
| 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 2835 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2846 | 2846 |
| 2847 | 2847 |
| 2848 // StoreInstanceFieldNode does not return result. | 2848 // StoreInstanceFieldNode does not return result. |
| 2849 void ValueGraphVisitor::VisitStoreInstanceFieldNode( | 2849 void ValueGraphVisitor::VisitStoreInstanceFieldNode( |
| 2850 StoreInstanceFieldNode* node) { | 2850 StoreInstanceFieldNode* node) { |
| 2851 UNIMPLEMENTED(); | 2851 UNIMPLEMENTED(); |
| 2852 } | 2852 } |
| 2853 | 2853 |
| 2854 | 2854 |
| 2855 void EffectGraphVisitor::VisitLoadStaticFieldNode(LoadStaticFieldNode* node) { | 2855 void EffectGraphVisitor::VisitLoadStaticFieldNode(LoadStaticFieldNode* node) { |
| 2856 LoadStaticFieldInstr* load = new LoadStaticFieldInstr(node->field()); | 2856 Value* field_value = Bind(new ConstantInstr(node->field())); |
| 2857 LoadStaticFieldInstr* load = new LoadStaticFieldInstr(field_value); |
| 2857 ReturnDefinition(load); | 2858 ReturnDefinition(load); |
| 2858 } | 2859 } |
| 2859 | 2860 |
| 2860 | 2861 |
| 2861 Definition* EffectGraphVisitor::BuildStoreStaticField( | 2862 Definition* EffectGraphVisitor::BuildStoreStaticField( |
| 2862 StoreStaticFieldNode* node, bool result_is_needed) { | 2863 StoreStaticFieldNode* node, bool result_is_needed) { |
| 2863 ValueGraphVisitor for_value(owner(), temp_index()); | 2864 ValueGraphVisitor for_value(owner(), temp_index()); |
| 2864 node->value()->Visit(&for_value); | 2865 node->value()->Visit(&for_value); |
| 2865 Append(for_value); | 2866 Append(for_value); |
| 2866 Value* store_value = NULL; | 2867 Value* store_value = NULL; |
| (...skipping 623 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3490 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1; | 3491 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1; |
| 3491 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); | 3492 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); |
| 3492 OS::SNPrint(chars, len, kFormat, function_name, reason); | 3493 OS::SNPrint(chars, len, kFormat, function_name, reason); |
| 3493 const Error& error = Error::Handle( | 3494 const Error& error = Error::Handle( |
| 3494 LanguageError::New(String::Handle(String::New(chars)))); | 3495 LanguageError::New(String::Handle(String::New(chars)))); |
| 3495 Isolate::Current()->long_jump_base()->Jump(1, error); | 3496 Isolate::Current()->long_jump_base()->Jump(1, error); |
| 3496 } | 3497 } |
| 3497 | 3498 |
| 3498 | 3499 |
| 3499 } // namespace dart | 3500 } // namespace dart |
| OLD | NEW |