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

Unified Diff: runtime/vm/compiler.cc

Issue 9395016: First part of new ICData infrastructure: use a wrapper object instead of an array. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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
Index: runtime/vm/compiler.cc
===================================================================
--- runtime/vm/compiler.cc (revision 4401)
+++ runtime/vm/compiler.cc (working copy)
@@ -52,8 +52,8 @@
GrowableArray<AstNode*> all_nodes;
sequence_node->CollectAllNodes(&all_nodes);
GrowableArray<intptr_t> node_ids;
- GrowableArray<const Array*> arrays;
- code.ExtractIcDataArraysAtCalls(&node_ids, &arrays);
+ GrowableArray<const ICData*> ic_data_objs;
+ code.ExtractIcDataArraysAtCalls(&node_ids, &ic_data_objs);
for (intptr_t i = 0; i < node_ids.length(); i++) {
intptr_t node_id = node_ids[i];
bool found_node = false;
@@ -61,8 +61,8 @@
if (all_nodes[n]->HasId(node_id)) {
found_node = true;
// Make sure we assign ic data array only once.
- ASSERT(all_nodes[n]->ICDataAtId(node_id).NumberOfChecks() == 0);
- all_nodes[n]->SetIcDataArrayAtId(node_id, *arrays[i]);
+ ASSERT(all_nodes[n]->ICDataAtId(node_id).IsNull());
+ all_nodes[n]->SetIcDataAtId(node_id, *ic_data_objs[i]);
}
}
ASSERT(found_node);

Powered by Google App Engine
This is Rietveld 408576698