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

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

Issue 1712563006: Cleanup access to guarded_fields (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 10 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
« no previous file with comments | « runtime/vm/flow_graph_builder.h ('k') | runtime/vm/flow_graph_inliner.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/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/bit_vector.h" 9 #include "vm/bit_vector.h"
10 #include "vm/compiler.h" 10 #include "vm/compiler.h"
(...skipping 3654 matching lines...) Expand 10 before | Expand all | Expand 10 after
3665 LoadFieldInstr* load = new(Z) LoadFieldInstr( 3665 LoadFieldInstr* load = new(Z) LoadFieldInstr(
3666 for_instance.value(), 3666 for_instance.value(),
3667 &node->field(), 3667 &node->field(),
3668 AbstractType::ZoneHandle(Z, node->field().type()), 3668 AbstractType::ZoneHandle(Z, node->field().type()),
3669 node->token_pos()); 3669 node->token_pos());
3670 if (node->field().guarded_cid() != kIllegalCid) { 3670 if (node->field().guarded_cid() != kIllegalCid) {
3671 if (!node->field().is_nullable() || 3671 if (!node->field().is_nullable() ||
3672 (node->field().guarded_cid() == kNullCid)) { 3672 (node->field().guarded_cid() == kNullCid)) {
3673 load->set_result_cid(node->field().guarded_cid()); 3673 load->set_result_cid(node->field().guarded_cid());
3674 } 3674 }
3675 FlowGraph::AddToGuardedFields(owner()->guarded_fields(), &node->field()); 3675 owner()->parsed_function().AddToGuardedFields(&node->field());
3676 } 3676 }
3677 ReturnDefinition(load); 3677 ReturnDefinition(load);
3678 } 3678 }
3679 3679
3680 3680
3681 void EffectGraphVisitor::VisitStoreInstanceFieldNode( 3681 void EffectGraphVisitor::VisitStoreInstanceFieldNode(
3682 StoreInstanceFieldNode* node) { 3682 StoreInstanceFieldNode* node) {
3683 const TokenPosition token_pos = node->token_pos(); 3683 const TokenPosition token_pos = node->token_pos();
3684 ValueGraphVisitor for_instance(owner()); 3684 ValueGraphVisitor for_instance(owner());
3685 node->instance()->Visit(&for_instance); 3685 node->instance()->Visit(&for_instance);
(...skipping 965 matching lines...) Expand 10 before | Expand all | Expand 10 after
4651 Script::Handle(function.script()), 4651 Script::Handle(function.script()),
4652 function.token_pos(), 4652 function.token_pos(),
4653 Report::AtLocation, 4653 Report::AtLocation,
4654 "FlowGraphBuilder Bailout: %s %s", 4654 "FlowGraphBuilder Bailout: %s %s",
4655 String::Handle(function.name()).ToCString(), 4655 String::Handle(function.name()).ToCString(),
4656 reason); 4656 reason);
4657 UNREACHABLE(); 4657 UNREACHABLE();
4658 } 4658 }
4659 4659
4660 } // namespace dart 4660 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_builder.h ('k') | runtime/vm/flow_graph_inliner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698