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

Unified Diff: src/compiler/access-info.cc

Issue 2883883002: [turbofan] Properly merge compatible field access infos. (Closed)
Patch Set: Created 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/access-info.cc
diff --git a/src/compiler/access-info.cc b/src/compiler/access-info.cc
index d43d96552a304535d4d9cc815889e8da6debe3ff..0acc6d1d564113dc888feffb88792551e684226f 100644
--- a/src/compiler/access-info.cc
+++ b/src/compiler/access-info.cc
@@ -145,9 +145,12 @@ bool PropertyAccessInfo::Merge(PropertyAccessInfo const* that,
case kDataField:
case kDataConstantField: {
- // Check if we actually access the same field.
- if (this->kind_ == that->kind_ &&
- this->field_index_ == that->field_index_) {
+ // Check if we actually access the same field (we use the
+ // GetFieldAccessStubKey method here just like the ICs do
+ // since that way we only compare the relevant bits of the
+ // field indices).
+ if (this->field_index_.GetFieldAccessStubKey() ==
+ that->field_index_.GetFieldAccessStubKey()) {
switch (access_mode) {
case AccessMode::kLoad: {
if (this->field_representation_ != that->field_representation_) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698