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

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

Issue 2693913002: [IC] Also use LoadNonexistentDH for keyed loads (Closed)
Patch Set: Created 3 years, 10 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 <iostream> 7 #include <iostream>
8 8
9 #include "src/accessors.h" 9 #include "src/accessors.h"
10 #include "src/api-arguments-inl.h" 10 #include "src/api-arguments-inl.h"
(...skipping 1112 matching lines...) Expand 10 before | Expand all | Expand 10 after
1123 ConfigureVectorState(PREMONOMORPHIC, Handle<Object>()); 1123 ConfigureVectorState(PREMONOMORPHIC, Handle<Object>());
1124 TRACE_IC("LoadIC", lookup->name()); 1124 TRACE_IC("LoadIC", lookup->name());
1125 return; 1125 return;
1126 } 1126 }
1127 1127
1128 Handle<Object> code; 1128 Handle<Object> code;
1129 if (lookup->state() == LookupIterator::JSPROXY || 1129 if (lookup->state() == LookupIterator::JSPROXY ||
1130 lookup->state() == LookupIterator::ACCESS_CHECK) { 1130 lookup->state() == LookupIterator::ACCESS_CHECK) {
1131 code = slow_stub(); 1131 code = slow_stub();
1132 } else if (!lookup->IsFound()) { 1132 } else if (!lookup->IsFound()) {
1133 if (IsLoadIC() || IsLoadGlobalIC()) { 1133 TRACE_HANDLER_STATS(isolate(), LoadIC_LoadNonexistentDH);
1134 TRACE_HANDLER_STATS(isolate(), LoadIC_LoadNonexistentDH); 1134 code = LoadNonExistent(receiver_map(), lookup->name());
1135 code = LoadNonExistent(receiver_map(), lookup->name());
1136 } else {
1137 code = slow_stub();
1138 }
1139 } else { 1135 } else {
1140 if (IsLoadGlobalIC() && lookup->state() == LookupIterator::DATA && 1136 if (IsLoadGlobalIC() && lookup->state() == LookupIterator::DATA &&
1141 lookup->GetReceiver().is_identical_to(lookup->GetHolder<Object>())) { 1137 lookup->GetReceiver().is_identical_to(lookup->GetHolder<Object>())) {
1142 DCHECK(lookup->GetReceiver()->IsJSGlobalObject()); 1138 DCHECK(lookup->GetReceiver()->IsJSGlobalObject());
1143 // Now update the cell in the feedback vector. 1139 // Now update the cell in the feedback vector.
1144 LoadGlobalICNexus* nexus = casted_nexus<LoadGlobalICNexus>(); 1140 LoadGlobalICNexus* nexus = casted_nexus<LoadGlobalICNexus>();
1145 nexus->ConfigurePropertyCellMode(lookup->GetPropertyCell()); 1141 nexus->ConfigurePropertyCellMode(lookup->GetPropertyCell());
1146 TRACE_IC("LoadGlobalIC", lookup->name()); 1142 TRACE_IC("LoadGlobalIC", lookup->name());
1147 return; 1143 return;
1148 } else if (lookup->state() == LookupIterator::ACCESSOR) { 1144 } else if (lookup->state() == LookupIterator::ACCESSOR) {
(...skipping 2006 matching lines...) Expand 10 before | Expand all | Expand 10 after
3155 DCHECK_EQ(LookupIterator::INTERCEPTOR, it.state()); 3151 DCHECK_EQ(LookupIterator::INTERCEPTOR, it.state());
3156 it.Next(); 3152 it.Next();
3157 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, result, 3153 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, result,
3158 Object::GetProperty(&it)); 3154 Object::GetProperty(&it));
3159 } 3155 }
3160 3156
3161 return *result; 3157 return *result;
3162 } 3158 }
3163 } // namespace internal 3159 } // namespace internal
3164 } // namespace v8 3160 } // 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