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

Side by Side Diff: src/ic/ic.cc

Issue 1406873002: [IC] Ensure we don't transition receivers when there's a data property in the hidden prototype chai… (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 2 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/ic/ic.h" 5 #include "src/ic/ic.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api.h" 8 #include "src/api.h"
9 #include "src/arguments.h" 9 #include "src/arguments.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 1471 matching lines...) Expand 10 before | Expand all | Expand 10 after
1482 return true; 1482 return true;
1483 } 1483 }
1484 1484
1485 // Receiver != holder. 1485 // Receiver != holder.
1486 PrototypeIterator iter(it->isolate(), receiver); 1486 PrototypeIterator iter(it->isolate(), receiver);
1487 if (receiver->IsJSGlobalProxy()) { 1487 if (receiver->IsJSGlobalProxy()) {
1488 return it->GetHolder<Object>().is_identical_to( 1488 return it->GetHolder<Object>().is_identical_to(
1489 PrototypeIterator::GetCurrent(iter)); 1489 PrototypeIterator::GetCurrent(iter));
1490 } 1490 }
1491 1491
1492 if (it->HolderIsReceiverOrHiddenPrototype()) return false;
1493
1492 it->PrepareTransitionToDataProperty(value, NONE, store_mode); 1494 it->PrepareTransitionToDataProperty(value, NONE, store_mode);
1493 return it->IsCacheableTransition(); 1495 return it->IsCacheableTransition();
1494 } 1496 }
1495 } 1497 }
1496 } 1498 }
1497 1499
1498 it->PrepareTransitionToDataProperty(value, NONE, store_mode); 1500 it->PrepareTransitionToDataProperty(value, NONE, store_mode);
1499 return it->IsCacheableTransition(); 1501 return it->IsCacheableTransition();
1500 } 1502 }
1501 1503
(...skipping 1645 matching lines...) Expand 10 before | Expand all | Expand 10 after
3147 KeyedLoadICNexus nexus(vector, vector_slot); 3149 KeyedLoadICNexus nexus(vector, vector_slot);
3148 KeyedLoadIC ic(IC::EXTRA_CALL_FRAME, isolate, &nexus); 3150 KeyedLoadIC ic(IC::EXTRA_CALL_FRAME, isolate, &nexus);
3149 ic.UpdateState(receiver, key); 3151 ic.UpdateState(receiver, key);
3150 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, result, ic.Load(receiver, key)); 3152 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, result, ic.Load(receiver, key));
3151 } 3153 }
3152 3154
3153 return *result; 3155 return *result;
3154 } 3156 }
3155 } // namespace internal 3157 } // namespace internal
3156 } // namespace v8 3158 } // namespace v8
OLDNEW
« 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