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

Unified Diff: src/hydrogen-store-elimination.cc

Issue 295743002: Refactor transitioning stores. (Closed) Base URL: git@github.com:v8/v8.git@master
Patch Set: Created 6 years, 7 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 | « src/hydrogen-load-elimination.cc ('k') | src/ia32/lithium-codegen-ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen-store-elimination.cc
diff --git a/src/hydrogen-store-elimination.cc b/src/hydrogen-store-elimination.cc
index cf5f3a15e69822491cb8e0ebda685fd576223f95..f6f85da760045eb10dd7ac2638d76a1d877f55fd 100644
--- a/src/hydrogen-store-elimination.cc
+++ b/src/hydrogen-store-elimination.cc
@@ -58,7 +58,11 @@ void HStoreEliminationPhase::ProcessStore(HStoreNamedField* store) {
while (i < unobserved_.length()) {
HStoreNamedField* prev = unobserved_.at(i);
if (aliasing_->MustAlias(object, prev->object()->ActualValue()) &&
- store->access().Equals(prev->access())) {
+ store->access().Equals(prev->access()) &&
+ (!SmiValuesAre32Bits() ||
+ !store->field_representation().IsSmi() ||
+ store->store_mode() == STORE_TO_INITIALIZED_ENTRY ||
+ prev->store_mode() == INITIALIZING_STORE)) {
// This store is guaranteed to overwrite the previous store.
prev->DeleteAndReplaceWith(NULL);
TRACE(("++ Unobserved store S%d overwritten by S%d\n",
@@ -69,11 +73,8 @@ void HStoreEliminationPhase::ProcessStore(HStoreNamedField* store) {
i++;
}
}
- // Only non-transitioning stores are removable.
- if (!store->has_transition()) {
- TRACE(("-- Might remove store S%d\n", store->id()));
- unobserved_.Add(store, zone());
- }
+ TRACE(("-- Might remove store S%d\n", store->id()));
+ unobserved_.Add(store, zone());
}
« no previous file with comments | « src/hydrogen-load-elimination.cc ('k') | src/ia32/lithium-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698