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

Unified Diff: src/ic.cc

Issue 176843018: Only use the non-strict-arguments-stub if the store site is non-strict. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix the fix 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 | test/mjsunit/regress-keyed-store-non-strict-arguments.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic.cc
diff --git a/src/ic.cc b/src/ic.cc
index 2607bb3b68d53405be03865fe60538dea4e8b9e0..3c9f1b66922f147ee4f28925dfdef34ce96f1dc2 100644
--- a/src/ic.cc
+++ b/src/ic.cc
@@ -1689,7 +1689,9 @@ MaybeObject* KeyedStoreIC::Store(Handle<Object> object,
bool key_is_smi_like = key->IsSmi() || !key->ToSmi()->IsFailure();
if (receiver->elements()->map() ==
isolate()->heap()->non_strict_arguments_elements_map()) {
- stub = non_strict_arguments_stub();
+ if (strict_mode() == kNonStrictMode) {
+ stub = non_strict_arguments_stub();
+ }
} else if (key_is_smi_like &&
!(target().is_identical_to(non_strict_arguments_stub()))) {
// We should go generic if receiver isn't a dictionary, but our
« no previous file with comments | « no previous file | test/mjsunit/regress-keyed-store-non-strict-arguments.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698