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

Unified Diff: runtime/vm/compiler.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/vm/flow_graph.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/compiler.cc
diff --git a/runtime/vm/compiler.cc b/runtime/vm/compiler.cc
index 0578d0ea61883b71158c73a3e30d0773a806c07f..fcab75e3fefb12fe47cbdf506932f92cfbc41682 100644
--- a/runtime/vm/compiler.cc
+++ b/runtime/vm/compiler.cc
@@ -489,7 +489,7 @@ void CompileParsedFunctionHelper::FinalizeCompilation(
}
}
}
- if (!flow_graph->guarded_fields()->is_empty()) {
+ if (!flow_graph->parsed_function().guarded_fields()->is_empty()) {
if (field_invalidation_gen_at_start() !=
isolate()->field_invalidation_gen()) {
code_is_valid = false;
@@ -526,10 +526,10 @@ void CompileParsedFunctionHelper::FinalizeCompilation(
++i) {
thread()->cha()->leaf_classes()[i]->RegisterCHACode(code);
}
- for (intptr_t i = 0;
- i < flow_graph->guarded_fields()->length();
- i++) {
- const Field* field = (*flow_graph->guarded_fields())[i];
+ const ZoneGrowableArray<const Field*>& guarded_fields =
+ *flow_graph->parsed_function().guarded_fields();
+ for (intptr_t i = 0; i < guarded_fields.length(); i++) {
+ const Field* field = guarded_fields[i];
field->RegisterDependentCode(code);
}
} else { // not optimized.
« no previous file with comments | « no previous file | runtime/vm/flow_graph.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698