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

Unified Diff: runtime/vm/flow_graph.cc

Issue 197283004: Generate smaller unoptimized code for certain expressions. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/vm/flow_graph_builder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/flow_graph.cc
===================================================================
--- runtime/vm/flow_graph.cc (revision 33576)
+++ runtime/vm/flow_graph.cc (working copy)
@@ -868,11 +868,10 @@
(push != NULL) ||
(drop != NULL) ||
(constant != NULL)) {
- intptr_t index;
- Definition* result;
+ Definition* result = NULL;
if (store != NULL) {
// Update renaming environment.
- index = store->local().BitIndexIn(num_non_copied_params_);
+ intptr_t index = store->local().BitIndexIn(num_non_copied_params_);
result = store->value()->definition();
if (variable_liveness->IsStoreAlive(block_entry, store)) {
@@ -884,7 +883,7 @@
// The graph construction ensures we do not have an unused LoadLocal
// computation.
ASSERT(definition->is_used());
- index = load->local().BitIndexIn(num_non_copied_params_);
+ intptr_t index = load->local().BitIndexIn(num_non_copied_params_);
result = (*env)[index];
PhiInstr* phi = result->AsPhi();
@@ -906,7 +905,10 @@
for (intptr_t j = 0; j < drop->num_temps(); j++) {
env->RemoveLast();
}
- result = drop->value()->definition();
+ if (drop->value() != NULL) {
+ result = drop->value()->definition();
+ }
+ ASSERT((drop->value() != NULL) || !drop->is_used());
} else {
ASSERT(definition->is_used());
result = GetConstant(constant->value());
« no previous file with comments | « no previous file | runtime/vm/flow_graph_builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698