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

Side by Side Diff: src/type-info.cc

Issue 137083002: Get rid of ContextualMode for call ICs. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Restore HCallGlobal until a follow-up CL Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « src/type-info.h ('k') | src/typing.cc » ('j') | 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 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 return KeyedStoreIC::GetKeyedAccessStoreMode(code->extra_ic_state()); 171 return KeyedStoreIC::GetKeyedAccessStoreMode(code->extra_ic_state());
172 } 172 }
173 } 173 }
174 return STANDARD_STORE; 174 return STANDARD_STORE;
175 } 175 }
176 176
177 177
178 void TypeFeedbackOracle::CallReceiverTypes(TypeFeedbackId id, 178 void TypeFeedbackOracle::CallReceiverTypes(TypeFeedbackId id,
179 Handle<String> name, 179 Handle<String> name,
180 int arity, 180 int arity,
181 ContextualMode contextual_mode,
182 SmallMapList* types) { 181 SmallMapList* types) {
183 // Note: Currently we do not take string extra ic data into account 182 // Note: Currently we do not take string extra ic data into account
184 // here. 183 // here.
185 ExtraICState extra_ic_state =
186 CallIC::Contextual::encode(contextual_mode);
187 Code::Flags flags = Code::ComputeMonomorphicFlags( 184 Code::Flags flags = Code::ComputeMonomorphicFlags(
188 Code::CALL_IC, extra_ic_state, OWN_MAP, Code::NORMAL, arity); 185 Code::CALL_IC, kNoExtraICState, OWN_MAP, Code::NORMAL, arity);
189 CollectReceiverTypes(id, name, flags, types); 186 CollectReceiverTypes(id, name, flags, types);
190 } 187 }
191 188
192 189
193 CheckType TypeFeedbackOracle::GetCallCheckType(TypeFeedbackId id) { 190 CheckType TypeFeedbackOracle::GetCallCheckType(TypeFeedbackId id) {
194 Handle<Object> value = GetInfo(id); 191 Handle<Object> value = GetInfo(id);
195 if (!value->IsSmi()) return RECEIVER_MAP_CHECK; 192 if (!value->IsSmi()) return RECEIVER_MAP_CHECK;
196 CheckType check = static_cast<CheckType>(Smi::cast(*value)->value()); 193 CheckType check = static_cast<CheckType>(Smi::cast(*value)->value());
197 ASSERT(check != RECEIVER_MAP_CHECK); 194 ASSERT(check != RECEIVER_MAP_CHECK);
198 return check; 195 return check;
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
571 #ifdef DEBUG 568 #ifdef DEBUG
572 Object* result = NULL; 569 Object* result = NULL;
573 // Dictionary has been allocated with sufficient size for all elements. 570 // Dictionary has been allocated with sufficient size for all elements.
574 ASSERT(maybe_result->ToObject(&result)); 571 ASSERT(maybe_result->ToObject(&result));
575 ASSERT(*dictionary_ == result); 572 ASSERT(*dictionary_ == result);
576 #endif 573 #endif
577 } 574 }
578 575
579 576
580 } } // namespace v8::internal 577 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/type-info.h ('k') | src/typing.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698