summaryrefslogtreecommitdiff
path: root/compiler/optimizing
diff options
context:
space:
mode:
author Mingyao Yang <mingyao@google.com> 2015-10-24 00:44:17 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2015-10-24 00:44:17 +0000
commit60b3f9f8b6f64290eec98b1180b92ec047ba4923 (patch)
tree53d917afc88d97a5ccae881720075aacf573e1c5 /compiler/optimizing
parentb5172e8e8c4a5cfff5a0bdb0a7f1810ee9c7bbd1 (diff)
parente9d6e6083e845194548e0705fdf9e172c7a043e5 (diff)
Merge "Disable store elimination on singleton object."
Diffstat (limited to 'compiler/optimizing')
-rw-r--r--compiler/optimizing/load_store_elimination.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/optimizing/load_store_elimination.cc b/compiler/optimizing/load_store_elimination.cc
index 68d02a4383..90f28e511e 100644
--- a/compiler/optimizing/load_store_elimination.cc
+++ b/compiler/optimizing/load_store_elimination.cc
@@ -695,12 +695,15 @@ class LSEVisitor : public HGraphVisitor {
} else {
redundant_store = true;
}
+ // TODO: eliminate the store if the singleton object is not finalizable.
+ redundant_store = false;
}
if (redundant_store) {
removed_instructions_.push_back(instruction);
substitute_instructions_.push_back(nullptr);
TryRemovingNullCheck(instruction);
}
+
heap_values[idx] = value;
// This store may kill values in other heap locations due to aliasing.
for (size_t i = 0; i < heap_values.size(); i++) {